Purpose
You can use this statement to switch the RootService role.
This statement can be executed only in the sys tenant.
Syntax
alter_system_rootservice_stmt:
ALTER SYSTEM SWITCH ROOTSERVICE {LEADER | FOLLOWER} {zone | server};
Parameters
| Parameter | Description |
|---|---|
| LEADER | FOLLOWER | Sets the RootService role to Leader or Follower. |
| zone | server | Modifies the RootService role of a specified zone or server. |
Examples
Switch the RootService role of z1 to Leader.
obclient> ALTER SYSTEM SWITCH ROOTSERVICE LEADER ZONE 'z1';