CSD for streaming Mode
Trigger CSD in streaming mode
Create Replication Slot on Primary
SELECT * FROM pg_create_physical_replication_slot(SLOT_NAME, false, false) WHERE NOT EXISTS (SELECT * FROM pg_replication_slots WHERE slot_name = SLOT_NAME)
On Primary MP find and Tar the postgresql config files, Including
postgres.conf
pg_ident.conf
pg_hba.conf
On Standby MP receive tar ball of postgresql config files from Primary server
Data directory setup: Using pg_basebackup to initialize streaming backup from Standby to Primary to retrieve all files in data directory from Primary with the Replication Slot created on step 2
/opt/rh/rh-postgresql13/root/usr/bin/pg_basebackup -D /var/lib/pgsql/data/13/main -F plain -X stream -S dbvisit_2 -R --progress --verbose --checkpoint=fast -d postgres://postgres@postgresqlcentos1:5432
Config directory setup: Extract files from tar ball recieved on step 4 and put them into the target config directory
After setting up data director and config directory, restart standby server
Applying the latest changes on configuration coming CSD and persisting configuration data on Control Center