postgresql 高可用 patroni + etcd 之二 patroni
                                                            生活随笔
收集整理的這篇文章主要介紹了
                                postgresql 高可用 patroni + etcd 之二 patroni
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.                        
                                os: centos 7.4
 postgresql: 9.6.9
 etcd: 3.2.18
 patroni: 1.4.4
patroni + etcd 是postgrsql 的一個(gè)高可用方案,依然是基于 postgreql stream replication。
ip規(guī)劃
192.168.56.101 node1 master 192.168.56.102 node2 slave 192.168.56.103 node3 slave安裝postgresql并配置好stream
node1、node2、node3 節(jié)點(diǎn)上注意設(shè)置如下幾個(gè)參數(shù)
synchronous_commit = on full_page_writes = on wal_log_hints = on synchronous_standby_names = '' max_replication_slots = 10node1上創(chuàng)建復(fù)制槽,至關(guān)重要,patroni 用到了這個(gè)玩意
postgres=# create user replicator replication login encrypted password '1qaz2wsx';postgres=# select * from pg_create_physical_replication_slot('pgsql96_node1'); postgres=# select * from pg_create_physical_replication_slot('pgsql96_node2'); postgres=# select * from pg_create_physical_replication_slot(總結(jié)
以上是生活随笔為你收集整理的postgresql 高可用 patroni + etcd 之二 patroni的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
                            
                        - 上一篇: RabbitMQ 学习 Shovel 插
 - 下一篇: 智慧电厂一体化建设解决方案