logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

o2cb - Cluster registration utility for the O2CB cluster stack.

Authors

       Oracle Corporation

Description

o2cb(8)  is  used  to  add,  remove and list the information in the O2CB cluster configuration file. This
       utility is also used to register and unregister the cluster, as well as start and stop global heartbeat.

       The default location of the configuration file, /etc/ocfs2/cluster.conf,  can  be  overridden  using  the
       --config-file option.

Example

       To create a cluster, mycluster having two nodes, node1 and node2, do:

       $ o2cb add-cluster mycluster
       $ o2cb add-node mycluster node1 --ip 10.10.10.1
       $ o2cb add-node mycluster node2 --ip 10.10.10.2

       Tospecifyaglobalheartbeatdevice,/dev/sda1,do:$o2cbadd-heartbeatmycluster/dev/sda1

       To enable global heartbeat, do:

       $ o2cb heartbeat-mode mycluster global

Name

       o2cb - Cluster registration utility for the O2CB cluster stack.

O2Cb Commands

add-clustercluster-name
              Adds a cluster to the configuration file. The O2CB configuration file can hold multiple  clusters.
              However, only one cluster can be active at any time.

       remove-clustercluster-name
              Removes  a  cluster  from the configuration file. This command removes all the nodes and heartbeat
              regions assigned to the cluster.

       add-nodecluster-namenode-name [--ipip-address] [--portport] [--numbernode-number]
              Adds a node to the cluster in the configuration file. It accepts three optional arguments.  If not
              provided, the ip-address defaults to the one assigned to the node-name, port to  7777,  and  node-number to the lowest unused node number.

       remove-nodecluster-namenode-name
              Removes a node from the cluster in the configuration file.

       add-heartbeatcluster-name [uuid|device]
              Adds a heartbeat region to the cluster in the configuration file.

       remove-heartbeatcluster-name [uuid|device]
              Removes a heartbeat region from the cluster in the configuration file.

       heartbeat-modecluster-name [local|global]
              Sets the heartbeat mode for the cluster in the configuration file.

       list-clusters
              Lists all the cluster names in the configuration file.

       list-clustercluster-name--oneline
              Lists all the nodes and heartbeat regions associated with the cluster in the configuration file.

       list-nodescluster-name--oneline
              Lists all the nodes associated with the cluster in the configuration file.

       list-heartbeatscluster-name--oneline
              Lists all the heartbeat regions associated with the cluster in the configuration file.

       register-clustercluster-name
              Registers  the cluster listed in the configuration file with configfs.  If called when the cluster
              is already registered, it will update configfs with the current configuration.

       unregister-clustercluster-name
              Unregisters the cluster from configfs.

       start-heartbeatcluster-name
              Starts global heartbeat on all regions for the cluster as listed in  the  configuration  file.  If
              repeated,  it  will  start  heartbeat  on  new  regions and stop on regions since removed. It will
              silently exit if global heartbeat has not been enabled.

       stop-heartbeatcluster-name
              Stops global heartbeat on all regions for the cluster. It will silently exit if  global  heartbeat
              has not been enabled.

       cluster-status[cluster-name]
              Shows  whether  the  given  cluster  is offline or online. If no cluster is provided, it shows the
              currently active cluster, if any.

Options

--config-fileconfig-file
              Specify  a  path  to  the  configuration  file.  If  not provided, it will use the default path of
              /etc/ocfs2/cluster.conf.

       -v,--verbose
              Verbose mode.

       -h,--help
              Help.

       -V,--version
              Show version and exit.

See Also

o2cb(7)o2cb.sysconfig(5)ocfs2.cluster.conf(5)

Synopsis

o2cb [--config-file=path] [-h|--help] [-v|--verbose] [-V|--version] COMMAND [ARGS]

See Also