Modifying the ZooKeeper Cluster: Execute the following command to modify the cluster level parameters of the ZooKeeper service.
zman server-role-zookeeper-update-cluster (zman srzuc)
The parameters of this command are:
-l --leader-connect-port: Define the leader port that the followers will use to connect to a leader in the cluster. The default port is 6790. However, you can specify an unused port between 6000 and 65535.
-c --client-port: Define the port on which ZooKeeper will listen in for incoming client connections. The default port is 6789. However, you can specify an unused port between 6000 and 65535.
-e --leader-elect-port: : Define the election port that all servers in the cluster will use to elect the leader. The default port is 6791. However, you can specify an unused port between 6000 and 65535.
-t --tick-time: Define the length of a single tick, which is a basic time unit in milliseconds, used by ZooKeeper to regulate heartbeats and timeouts. The default value is 2000.
-i --init-limit: Define the amount of time, in ticks, to allow followers to connect to the leader. The default value is 10.
-s --sync-limit: Define the amount of time, in ticks, to allow followers to sync with ZooKeeper. The default value is 5.
-m --max-cluster-size: Define the size of the Zookeeper cluster. The default value is 3.
-x --max-connections: Specify the maximum number of client connections that the ZooKeeper cluster can accept. The default value is 120.
For example: zman server-role-zookeeper-update-cluster -s=6
Removing additional ZooKeeper servers: Execute the following command to remove additional ZooKeeper servers:
zman server-role-zookeeper-remove-server (zman srzrs)
This command removes any additional servers from the existing cluster. Specify the DNS, GUID or path of the server object (server, server folder or server group) relative to /Devices/Servers. At least one server in the zone must have a ZooKeeper role enabled on it. Therefore, this command will not work if the server in which ZooKeeper role is enabled, is the last ZooKeeper server.
For example: zman server-role-zookeeper-remove-server --servers=server1.microfocus.com
Viewing list of ZooKeeper servers: Execute the following command to view the list of ZooKeeper servers in a cluster.
zman server-role-zookeeper-list-cluster (zman srzlc)