admin cluster bridge failover
Feature of Yandex Enterprise Database
This functionality is available only in the Yandex Enterprise Database. In the open-source version of YDB it is absent.
Use the admin cluster bridge failover command to perform emergency disable of a pile when it is unavailable. You can optionally specify the pile that will become the new PRIMARY.
Alert
Commands in this section can harm your cluster if used incorrectly. Due to the potentially dangerous nature of these commands, ALL global parameters must be specified explicitly. Profiles are disabled by default and are only used when explicitly specified (--profile <profile-name>). Some commands do not require global options that are otherwise mandatory.
General command syntax:
ydb [global options...] admin cluster bridge failover [options...]
global options— global parameters for the CLI.options— subcommand parameters.
View command help:
ydb admin cluster bridge failover --help
Subcommand parameters
|
Name |
Description |
|
|
Name of the unavailable pile. |
|
|
Name of the pile that should become the new |
Requirements
- If the current
PRIMARYis unavailable, you must specify--new-primaryand choose a pile in theSYNCHRONIZEDstate. If--new-primaryis missing or the chosen pile is not inSYNCHRONIZEDstate, the command returns an error without making any changes. - The cluster will not enter an invalid state: if requirements are violated, the command makes no changes and reports an error.
- If the pile has not failed but you need to disable it, use planned disable — the
takedowncommand.
Examples
Perform emergency disable for an unavailable pile named pile-a:
ydb admin cluster bridge failover --pile pile-a
Perform emergency disable for an unavailable PRIMARY pile and designate a synchronized pile as the new PRIMARY:
ydb admin cluster bridge failover --pile pile-a --new-primary pile-b
Verifying the result
Use the list command to verify that the unavailable pile has been moved to DISCONNECTED and (if --new-primary was specified) a new PRIMARY has been selected:
ydb admin cluster bridge list
pile-a: DISCONNECTED
pile-b: PRIMARY