sun.com | docs.sun.com |  | How To Buy | My Sun | Worldwide Sites |

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Maintenance Commands | nhnsmd(1M)

- NAME
- SYNOPSIS
- DESCRIPTION
- OPTIONS
- EXTENDED DESCRIPTION
- FILES
- ATTRIBUTES
- SEE ALSO

## NAME

> nhnsmd - Node State Manager daemon

## SYNOPSIS

> `/opt/SUNWcgha/sbin/nhnsmd` [-u URL]

## DESCRIPTION

> On the node holding the master role, a logical address is assigned to an interface that is used to connect to the external network. This address is called the floating external address. The Node State Manager (NSM) uses the Cluster Membership Manager (CMM) notifications to determine when a node is promoted to or demoted from being the master node. When the NSM is notified that a node has been promoted to master node, it executes a script to configure a floating external address for one of the node's external interfaces. When the NSM is notified that a node has been demoted from the master node, it executes a script to deconfigure the floating external address.

> The NSM can be used for tasks other than address management but this is not its intended function. If you configure the NSM for purposes other than to monitor the floating external address of the master node, you must consider the effect of this mechanism on cluster integrity.

## OPTIONS

> The `nhnsmd` daemon takes the following option:

> -u URL

>   You must specify the URL of the `nhfs.conf` file.

## EXTENDED DESCRIPTION

> Launch the `nhnsmd` manually as a superuser:

> >     # ./nhnsmd -u  URL

> The `nhnsmd` daemon is started at system boot time after the `nhcmmd` daemon. The `nhnsmd` daemon registers to receive the following notifications at cluster startup:

> - `CMM_MASTER_ELECTED`

> - `CMM_MASTER_DEMOTED`

> - `CMM_VICEMASTER_ELECTED`

> - `CMM_VICEMASTER_DEMOTED`

> The `nhnsmd` daemon executes a response to notifications in the order in which it receives them. It does not act upon a notification that does not pertain to the current state of the node for which the notification is received.

> The `nhnsmd` daemon maintains persistent state across failures so that when restarted by the Daemon Monitor it can determine whether it has missed any notifications and can take appropriate action. This persistent state is not maintained across a node reboot.

> The scripts executed by the `nhnsmd` daemon must be executable shell scripts.

> The first argument of the scripts is the action parameter. The action parameter can have two values, enter state and leave state. You can use the same script for both actions. For an enter state action, the script passes the string `enter` as the first argument. For a leave state action, the script is passed the string `leave` as the first argument.

> The second argument of the scripts is the node role parameter. The node role parameter is passed as a lower-case character string. The node role parameter can have two values, master and vice-master.

> The scripts executed by the `nhnsmd` daemon should not perform actions that change the startup behavior of the node. For any notification received, the `nhnsmd` daemon executes a script that invokes a node to leave an existing state and then a script that invokes that node to enter a new state.

> The script provided with Foundation Services handles address failover if the external master address is present on a separate external interface or on a logical interface on the cluster network.

> Scripts used by the `nhnsmd` daemon run as asynchronous processes and do not take account of any changes in the cluster state. When writing your own action scripts for the `nhnsmd` daemon do not write scripts that will take a long time to execute or that depend on cluster behavior. Such scripts should not be used as a way of controlling applications or as a replacement for a management framework.

## FILES

> `nhfs.conf`

>   Configuration and addressing information for the different Foundation Services. The URL for this file could be `file:///etc/opt/SUNWcgha/nhfs.conf`

> `/opt/SUNWcgha/actions/master`

>   This directory contains scripts for transitions to and from the master state.

> `/opt/SUNWcgha/actions/vicemaster`

>   This directory contains scripts for transitions to and from the vice-master state.

> The script names have the `Ennxxxxxx` or `Lnnxxxxxx` form, where `E` denotes an script to enter a state and `L` denotes a script to leave a state, nn is a two-digit numeric code, and xxxxxx is an arbitrary string of characters. Any files that do not use this naming scheme will be ignored by `nhnsmd`.

## ATTRIBUTES

> See `attributes`(5) for descriptions of the following attributes:

> ATTRIBUTE TYPE | ATTRIBUTE VALUE
> --- | ---
> Architecture | SPARC
> Availability | SUNWnhnsa, SUNWnhnsb
> Interface Stability | Evolving

## SEE ALSO

> `nhfs.conf`(4) and `nhpmd`(1M).

Netra HAS FS 2.1 | Go To Top | Last Changed September 2004

Company Info | Contact | Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.