Create replication slots
When you have configured postgresql.conf and restarted Postgres, you can create a [replication slot][postgres-rslots-docs] for each replica. Replication slots ensure that the primary does not delete segments from the WAL until they have been received by the replicas. This is important in case a replica goes down for an extended time. The primary needs to verify that a WAL segment has been consumed by a replica, so that it can safely delete data. You can use [archiving][postgres-archive-docs] for this purpose, but replication slots provide the strongest protection for streaming replication.
Creating replication slots
At the
psqlslot, create the first replication slot. The name of the slot is arbitrary. In this example, it is calledreplica_1_slot:Repeat for each required replication slot.