![]() ![]() Start PostgreSQL systemctl start postgresql-10Ĭreate the required users for replication and repmgr and the repmgr DB. Host replication repmgr 127.0.0.1/32 trust Pg_hba.conf is client authentication is controlled by a configuration file. Specifies the minimum number of past log file segments kept in the pg_xlog directory, in case a standby server needs to fetch them for streaming replication. wal_level = hot_standbyĪrchive_command = 'cp %p /var/lib/pgsql/10/archive/%f' This parameter can only be set at server start. archive adds logging required for WAL archiving, and hot_standby further adds information required to run read-only queries on a standby server. The default value is minimal, which writes only the information needed to recover from a crash or immediate shutdown. ![]() ![]() Wal_level determines how much information is written to the WAL. Set the value to 2 (since we have two servers, one master and one slave). usr/pgsql-10/bin/postgresql-10-setup initdbĬonfigure repmgr by editing /etc/repmgr/10/nf node_id=1Ĭonninfo='host= user=repmgr dbname=repmgr'Ĭonfigure PostgreSQL itself and streaming replication by editing /var/lib/pgsql/10/data/nfĬhange listener_address to master server ip listen_addresses = '*' Yum install postgresql10-server postgresql10-contrib repmgr10 Master Server Configuration Installation yum install 2 CentOS 7 servers (One will act as master and the other one as slave)įireWalld Configuration (Master Server And Slave Server) systemctl start firewalldįirewall-cmd -add-service=postgresql -permanent
0 Comments
Leave a Reply. |