From d89e666e0666a0023e4aa6b6b4c4d25d049c5215 Mon Sep 17 00:00:00 2001 From: zhanghailiang Date: Thu, 27 Oct 2016 14:43:03 +0800 Subject: COLO: Add 'x-colo-lost-heartbeat' command to trigger failover We leave users to choose whatever heartbeat solution they want, if the heartbeat is lost, or other errors they detect, they can use experimental command 'x_colo_lost_heartbeat' to tell COLO to do failover, COLO will do operations accordingly. For example, if the command is sent to the Primary side, the Primary side will exit COLO mode, does cleanup work, and then, PVM will take over the service work. If sent to the Secondary side, the Secondary side will run failover work, then takes over PVM's service work. Cc: Luiz Capitulino Cc: Eric Blake Cc: Markus Armbruster Signed-off-by: zhanghailiang Signed-off-by: Li Zhijian Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Amit Shah Signed-off-by: Amit Shah --- hmp-commands.hx | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'hmp-commands.hx') diff --git a/hmp-commands.hx b/hmp-commands.hx index 06bef470b9..88192817b2 100644 --- a/hmp-commands.hx +++ b/hmp-commands.hx @@ -1037,6 +1037,21 @@ STEXI @findex migrate_start_postcopy Switch in-progress migration to postcopy mode. Ignored after the end of migration (or once already in postcopy). +ETEXI + + { + .name = "x_colo_lost_heartbeat", + .args_type = "", + .params = "", + .help = "Tell COLO that heartbeat is lost,\n\t\t\t" + "a failover or takeover is needed.", + .cmd = hmp_x_colo_lost_heartbeat, + }, + +STEXI +@item x_colo_lost_heartbeat +@findex x_colo_lost_heartbeat +Tell COLO that heartbeat is lost, a failover or takeover is needed. ETEXI { -- cgit v1.2.1