PG_AUTOCTL GET NODE CANDIDATE-PRIORITY(1)
β¨ PG_AUTOCTL GET NODE CANDIDATE-PRIORITY β¨
okay bestie, welcome to the pg_auto_failover manual, this one's from pg_autoctl and it is genuinely so useful, i promise π
πΈ NAME πΈ
pg_autoctl get node candidate-priority β pg_autoctl get node candidate-priority
pg_autoctl get candidate-priority β bestie, this one grabs the candidate-priority property straight from the monitor β¨
π SYNOPSIS π
so basically, this command prints the pg_autoctl candidate priority for a given node:
usage: pg_autoctl get node candidate-priority [ --pgdata ] [ --json ] [ --formation ] [ --name ]
--pgdata path to data directory
--formation pg_auto_failover formation
--name pg_auto_failover node name
--json output data in the JSON format
π DESCRIPTION π
ngl, the one thing to know here is: also go look at pg_autoctl show settings if you want the full list of replication settings π like, that's where the whole menu lives.
β¨ OPTIONS β¨
--pgdataβ this is where the Postgres node you're managing locally keeps its data. defaults to the environment variablePGDATA. and like, use--monitorif you wanna connect to a monitor from literally anywhere, instead of using the monitor URI that a local Postgres node managed withpg_autoctlwould use π¦--jsonβ outputs the data in JSON format β¨--formationβ shows replication settings for the given formation. defaults todefaultπ--nameβ shows replication settings for the given node, picked out by name π
π EXAMPLES π
first one, no json, just the number, slay:
$ pg_autoctl get node candidate-priority --name node1
50
and now with --json because we love structured data in this house:
$ pg_autoctl get node candidate-priority --name node1 --json
{
"name": "node1",
"candidate-priority": 50
}
π AUTHOR π
Microsoft
π COPYRIGHT π
Copyright (c) Microsoft Corporation. All rights reserved.
okay that's the whole page bestie, go forth and check those priorities π«Ά
mwah π this was pg_autoctl get node candidate-priority, version 2.2, dated Apr 07, 2025, part of the pg_auto_failover family β ily, bye!! πΈβ¨π
π¦ where this page comes from
- debian trixie: pg-auto-failover-cli 2.2-2 Β· PostgreSQL
- ubuntu questing: pg-auto-failover-cli 2.2-2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms