6.3 Checking the operating system process
Once we have checked the archive and our system view, we are ready to check the system process. Checking the system process may look a bit rough, but it proves to be very effective.
On master, we can simply check a process called Wal_sender. On slave we want to check for a process called wal_receiver.
Let's first examine what we should see on master:
9314?? Ss 0:00.00 Postgres:wal Sender Process
HS:: 1 (61498) idle
On Linux we can see that the process not only has its own role (in this case, Wal_sender), but also comes with the name of the end user and the associated network connection information. In our example we can see that someone has already connected to master from a local port via 61498.
The situation on the slave is fairly simple:
9313?? Ss 0:00.00 Postgres:wal Receiver Process
All we see is a process that tells us that we are consuming xlog.
If there are two processes here, you've got a good indicator and your copy setup works well.
The sixth chapter of PostgreSQL Replication Monitoring your settings (3)