SHOW_POOL_NODES(1)

✨ SHOW_POOL_NODES β€” bestie, it's the node list πŸ’–

okay so real quick, this is a page from the pgpool-II 4.7.2 Documentation family, and it's all about one lil command that spills the tea on every node you've configured. πŸ«–

🌸 NAME 🌸

SHOW_POOL_NODES β€” sends back a list of all configured nodes ✨


πŸŽ€ SYNOPSIS πŸŽ€

SHOW POOL_NODES

πŸ¦‹ DESCRIPTION πŸ¦‹

so SHOW POOL_NODES is the main character here and she shows you everything: the node id, the hostname, the port, the status, the weight (ngl that one only actually means something if you're using load balancing mode), the role, the SELECT query counts issued to each backend, whether each node is the load balance node or not, the replication delay (only if you're in streaming replication mode, iykyk) and the last status change time. πŸ’…

and that's not even all of it β€” on top of that, replication state and sync state get shown for standby nodes in Pgpool-II 4.1 or after. 🫢 Also actual node status and node role are shown in Pgpool-II 4.3 or after. so if you're on an older version and wondering where those columns went... that's why bestie. πŸ™ˆ

the possible values in the status column are explained in the pcp_node_info(1) reference β€” go read that one if you need the deets on what each status actually means. πŸ“–

lowkey important: if the hostname is something like "/tmp", that means Pgpool-II is connecting to the backend by using UNIX domain sockets. that's not a typo, that's just the vibe. 🧚

more tea: the SELECT count does not include internal queries used by Pgpool-II. and the counters are reset to zero upon starting up of Pgpool-II. the last status change time is initially set to the time Pgpool-II starts, and after that, whenever "status" or "role" is changed, it gets updated. ⭐

here's an example session so you can see her in action:

test=# show pool_nodes;
 node_id | hostname | port  | status | pg_status | lb_weight |  role   | pg_role | select_cnt | load_balance_node | replication_delay | replication_state | replication_sync_state | last_status_change
---------+----------+-------+--------+-----------+-----------+---------+---------+------------+-------------------+-------------------+-------------------+------------------------+---------------------
 0       | /tmp     | 11002 | up     | up        | 0.500000  | primary | primary | 0          | false             | 0                 |                   |                        | 2021-02-27 15:10:19
 1       | /tmp     | 11003 | up     | up        | 0.500000  | standby | standby | 0          | true              | 0                 | streaming         | async                  | 2021-02-27 15:10:19
(2 rows)

and that's the whole page bestie, no cap β€” this was SHOW POOL_NODES(1) from the pgpool-II 4.7.2 Documentation, dated 2023. go query some nodes, you ate. πŸ‘‘πŸ’–

πŸ“¦ where this page comes from