Created
October 1, 2014 11:11
-
-
Save pfigue/fdc2064f7ca0f1342eef to your computer and use it in GitHub Desktop.
Monitor PostgreSQL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
psql -c "SELECT pg_is_in_recovery();" # true for standby, false for master | |
psql -c "SELECT txid_current_snapshot();" | |
psql -c "select pg_last_xlog_receive_location()" # from standby | |
psql -c "select pg_last_xlog_replay_location()" # from standby | |
psql -c "SELECT pg_current_xlog_location()" # from master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment