switchover v5.6
Switches over to new write leader.
Synopsis
Switches over to new write leader. Use switchover method fast
for immediate switchover. Use strict
to wait until lag is less than route_writer_max_lag
on the given target node.
If switchover fails due to timeout or any other issue, BDR might elect a write leader that's different from the given target node.
Options
Flag | Value | Description |
---|---|---|
--group-name | string | Group name |
--method | string | Switchover method (strict, fast) strict - waits until lag on given node is less than route_writer_max_lag fast - immediate switchover, route_writer_max_lag is ignored (default "strict") |
--node-name | string | Node name |
--timeout | interval | Timeout period when switchover method is strict (default 10s) |
See global options for global options.
Examples
Using defaults
Running the command with only required arguments. The default method is strict
and default timeout is 10s
.
Using optional arguments
Running the command with optional arguments.
Immediate switchover
Running the command with fast
method for immediate switchover.