Use the following procedure to monitor or unmonitor disk paths from a file.
To change your cluster configuration by using a file, you must first export the current configuration. This export operation creates an XML file that you can then modify to set the configuration items you are changing. The instructions in this procedure describe this entire process.
The phys-schost# prompt reflects a global-cluster prompt. Perform this procedure on a global cluster.
This procedure provides the long forms of the Oracle Solaris Cluster commands. Most commands also have short forms. Except for the long and short forms of the command names, the commands are identical.
# cldevice export -o configurationfile
Specify the file name for your XML file.
Find the device paths that you want to monitor, and set the monitored attribute to true.
# cldevice monitor -i configurationfile
Specify the file name of the modified XML file.
# cldevice status
In the following example, the device path between the node phys-schost–2 and device d3 is monitored by using an XML file.
The first step is to export the current cluster configuration.
# cldevice export -o deviceconfig
The deviceconfig XML file shows that the path between phys-schost–2 and d3 is not currently monitored.
<?xml version="1.0"?> <!DOCTYPE cluster SYSTEM "/usr/cluster/lib/xml/cluster.dtd"> <cluster name="brave_clus"> . . . <deviceList readonly="true"> <device name="d3" ctd="c1t8d0"> <devicePath nodeRef="phys-schost-1" monitored="true"/> <devicePath nodeRef="phys-schost-2" monitored="false"/> </device> </deviceList> </cluster>
To monitor that path, set the monitored attribute to true, as follows.
<?xml version="1.0"?> <!DOCTYPE cluster SYSTEM "/usr/cluster/lib/xml/cluster.dtd"> <cluster name="brave_clus"> . . . <deviceList readonly="true"> <device name="d3" ctd="c1t8d0"> <devicePath nodeRef="phys-schost-1" monitored="true"/> <devicePath nodeRef="phys-schost-2" monitored="true"/> </device> </deviceList> </cluster>
Use the cldevice command to read the file and turn on monitoring.
# cldevice monitor -i deviceconfig
Use the cldevice command to verify that the device is now monitored.
# cldevice status
See also
For more detail about exporting cluster configuration and using the resulting XML file to set cluster configuration, see the cluster(1CL) and the clconfiguration(5CL) man pages.