Sun Cluster 2.2 System Administration Guide

3.10 Modifying the clusters File

The /etc/clusters file contains information on the known clusters in the local naming domain. This file, which maps a cluster name to the list of host names in the cluster, can be created as an NIS or NIS+ map, or locally in the /etc directory.

The /etc/clusters file requires updating only if:

For more information on NIS and NIS+ maps, refer to the NIS/NIS+ System Administration Guide. Refer to the Sun Cluster 2.2 Software Installation Guide for information on creating the /etc/clusters file. NIS/NIS+ files must be changed on the NIS/NIS+ server.

3.10.1 How to Modify the clusters File

Edit the /etc/clusters file to add the cluster name and physical host names of all nodes.

For example, to create a cluster named hacluster that consists of node 0 phys-hahost1, node 1 phys-hahost2, node 2 phys-hahost3, and node 3 phys-hahost4, enter this command:

# Sun Enterprise Cluster nodes
  hacluster phys-hahost1 phys-hahost2 phys-hahost3 phys-hahost4

Make the same modifications in the /etc/clusters file on each cluster node.

3.10.2 How to Create the clusters Table

In an NIS+ environment, you must create a clusters table. The entries in this table are the same as the entries in the /etc/clusters file.

For example, to create a clusters table in a domain named mydomain in an NIS+ environment, use the following command:

# nistbladm -c key-value key=SI value= clusters.mydomain.

Note -

The trailing period (.) at the end of the nistbladm command is required.