PG_AUTOCTL_STATUS(1)
π
PG_AUTOCTL STATUS(1) β the pg_autoctl status page, bestie edition
okay so you're looking at the manual page for pg_autoctl status, and it lives inside the pg_auto_failover manual. Manual name's right there, no need to go hunting π
β¨ NAME β¨
pg_autoctl status β pg_autoctl status
pg_autoctl status β Display the current status of the pg_autoctl service
π¦ SYNOPSIS π¦
This command outputs the current process status for the pg_autoctl service running for the given --pgdata location.
usage: pg_autoctl status [ --pgdata ] [ --json ]
--pgdata path to data directory
--json output data in the JSON format
π OPTIONS π
--pgdataβ where your Postgres node lives locally, like, the one being managed. Defaults to the environment variablePGDATA, so if you already set that you don't gotta type it π--jsonβ instead of a cute little table-formatted list, you get JSON formatted data. very giving "machine readable", slay.
πΈ ENVIRONMENT πΈ
PGDATAβ Postgres directory location. Can be used instead of the--pgdataoption. (yes bestie, it's the substitute, use it.)PG_AUTOCTL_MONITORβ Postgres URI to connect to the monitor node.XDG_CONFIG_HOMEβ thepg_autoctlcommand stores its configuration files in the standard placeXDG_CONFIG_HOME. See the XDG Base Directory Specification.XDG_DATA_HOMEβ thepg_autoctlcommand stores its internal states files in the standard placeXDG_DATA_HOME, which defaults to~/.local/share. See the XDG Base Directory Specification.
π EXAMPLE π
no cap, here's what it actually looks like:
$ pg_autoctl status --pgdata node1
11:26:30 27248 INFO pg_autoctl is running with pid 26618
11:26:30 27248 INFO Postgres is serving PGDATA "/Users/dim/dev/MS/pg_auto_failover/tmux/node1" on port 5501 with pid 26725
$ pg_autoctl status --pgdata node1 --json
11:26:37 27385 INFO pg_autoctl is running with pid 26618
11:26:37 27385 INFO Postgres is serving PGDATA "/Users/dim/dev/MS/pg_auto_failover/tmux/node1" on port 5501 with pid 26725
{
"postgres": {
"pgdata": "\/Users\/dim\/dev\/MS\/pg_auto_failover\/tmux\/node1",
"pg_ctl": "\/Applications\/Postgres.app\/Contents\/Versions\/12\/bin\/pg_ctl",
"version": "12.3",
"host": "\/tmp",
"port": 5501,
"proxyport": 0,
"pid": 26725,
"in_recovery": false,
"control": {
"version": 0,
"catalog_version": 0,
"system_identifier": "0"
},
"postmaster": {
"status": "ready"
}
},
"pg_autoctl": {
"pid": 26618,
"status": "running",
"pgdata": "\/Users\/dim\/dev\/MS\/pg_auto_failover\/tmux\/node1",
"version": "1.5.0",
"semId": 196609,
"services": [
{
"name": "postgres",
"pid": 26625,
"status": "running",
"version": "1.5.0",
"pgautofailover": "1.5.0.1"
},
{
"name": "node-active",
"pid": 26626,
"status": "running",
"version": "1.5.0",
"pgautofailover": "1.5.0.1"
}
]
}
}
likeβ¦ look at all those pids and services living their truth π iconic.
π«Ά AUTHOR π«Ά
Microsoft
π COPYRIGHT π
Copyright (c) Microsoft Corporation. All rights reserved.
ok that's the whole page, you read all of it, main character energy fr fr π§
and a lil sign-off for the girlies: this is version 2.1, dated Jan 18, 2025, and yeah it's the PG_AUTOCTL STATUS(1) page, periodt πβ¨
π¦ where this page comes from
- fedora 43: pg_auto_failover 2.1-6.fc42 Β· Apache-1.0
- fedora 44: pg_auto_failover 2.1-6.fc42 Β· Apache-1.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms