Hello Everyone,
Apologies in advance I don't know where to get knowledge regarding this issue that's why I posted here, Highly appreciated if someone could help on this regard
We have installed and configured PostgreSQL V13 Master- Slave streaming replication on Windows server 2016 but replication is not working. I don't know where the error is because we are not facing any error regarding replication and replication also not working.
Below are the Configuration steps performed on Master and Slave Server
Master Server postgresql.conf file changes made
listen_addresses = '*'
wal_level = replica
wal_writer_delay = 500ms
archive_mode = on
archive_command ='copy %p \\server IP\wal_archive\%f"'
archive_timeout = 3600
max_wal_senders = 6
max_replication_slots = 6
pg_hba Master Server File
host replication username slave_ip/32 md5
host replication username master_ip/32 md5
Below are the Configuration steps performed on Slave Server
Note: I have copied Data directory from master server and paste it on Slave server
Slave Server postgresql.conf file changes made
listen_addresses = '*'
wal_level = replica
wal_writer_delay = 500ms
#archive_mode = off
max_wal_senders = 6
hot_standby = on
Slave pg_hba.conf file
host replication username slave_ip/32 md5
host replication username master_ip/32 md5
recovery.conf file
standby_mode = 'on'
restore_command= 'copy "C:\wal_archive\%f" %p'
<primary_conninfo> = 'host=<MasterIP> port=5432 user=replicator password=*****'
After all these changes made when I restart the master and slave server and run the following command on master server to check whether replication is working or not the below mention query return 0 row
Master Server select * from pg_stat_replication" (return 0 row)
Would be highly appreciated, if someone could tell me what exactly the issue is or what I am missing in the configuration on both the servers (master- slave).Why replication is not working?