Sun Cluster 2.2 API Developer's Guide

Registering a Data Service

A data service is registered with Sun Cluster using the hareg(1M) program. Registration is persistent in that it survives across takeovers, switchovers, and reboots. Registration with Sun Cluster is usually done as the last step of installing and configuring a data service. Registration is a one-time event. A data service also can be unregistered with hareg(1M). See the hareg(1M) man page for details.

In addition to the distinction between registered versus unregistered, Sun Cluster has the concept of a data service being either "on" or "off." The purpose of the "on" or "off" state is to provide the system administrator with a mechanism for temporarily shutting down a data service without taking the more drastic step of unregistering it. For example, a system administrator can turn a data service "off" to do stand-alone backups. While the data service is "off," it is not providing service to clients. When a data service is "off," the parameters that Sun Cluster passes to the data service's methods indicate that the data service should not be servicing data from any of the logical hosts.

When a data service is first registered with Sun Cluster, its initial state is "off." The hareg(1M) program is used to transition a data service between the "off" and "on" states. The work of moving a data service between states is accomplished through a reconfiguration as described in the hareg(1M) man page.

Before unregistering a data service, the system administrator first must transition the data service into the "off" state by calling hareg(1M).