diff --git a/doc/repmgrd-automatic-failover.sgml b/doc/repmgrd-automatic-failover.sgml index fdb70557..217eb1ef 100644 --- a/doc/repmgrd-automatic-failover.sgml +++ b/doc/repmgrd-automatic-failover.sgml @@ -269,7 +269,46 @@ Standby disconnections monitoring process example + This example shows typical repmgrd log output from a three-node cluster + (primary and two child nodes), with child_nodes_connected_min_count + set to 2. + + repmgrd on the primary has started up, while two child + nodes are being provisioned: + +[2019-04-24 15:25:33] [INFO] monitoring primary node "node1" (node ID: 1) in normal state +[2019-04-24 15:25:35] [NOTICE] new node "node2" (node ID: 2) has connected +[2019-04-24 15:25:35] [NOTICE] 1 (of 1) child nodes are connected, but at least 2 child nodes required +[2019-04-24 15:25:35] [INFO] no child nodes have detached since repmgrd startup +(...) +[2019-04-24 15:25:44] [NOTICE] new node "node3" (node ID: 3) has connected +[2019-04-24 15:25:46] [INFO] monitoring primary node "node1" (node ID: 1) in normal state +(...) + + + One of the child nodes has disconnected; repmgrd + is now waiting child_nodes_disconnect_timeout seconds + before executing child_nodes_disconnect_command: + +[2019-04-24 15:28:11] [INFO] monitoring primary node "node1" (node ID: 1) in normal state +[2019-04-24 15:28:17] [INFO] monitoring primary node "node1" (node ID: 1) in normal state +[2019-04-24 15:28:19] [NOTICE] node "node3" (node ID: 3) has disconnected +[2019-04-24 15:28:19] [NOTICE] 1 (of 2) child nodes are connected, but at least 2 child nodes required +[2019-04-24 15:28:19] [INFO] most recently detached child node was 3 (ca. 0 seconds ago), not triggering "child_nodes_disconnect_command" +[2019-04-24 15:28:19] [DETAIL] "child_nodes_disconnect_timeout" set To 30 seconds +(...) + + + child_nodes_disconnect_command is executed once: + +[2019-04-24 15:28:49] [INFO] most recently detached child node was 3 (ca. 30 seconds ago), triggering "child_nodes_disconnect_command" +[2019-04-24 15:28:49] [INFO] "child_nodes_disconnect_command" is: + "/usr/bin/fence-all-the-things.sh" +[2019-04-24 15:28:51] [NOTICE] 1 (of 2) child nodes are connected, but at least 2 child nodes required +[2019-04-24 15:28:51] [INFO] "child_nodes_disconnect_command" was previously executed, taking no action + + @@ -319,6 +358,12 @@ to be executed by the system user under which the PostgreSQL server itself runs (usually postgres). + + + If child_nodes_disconnect_command is not set, no action + will be taken. + + If specified, the following format placeholder will be substituted when executing child_nodes_disconnect_command: