#!/usr/bin/ksh
#
# Copyright (c) 2005 by Sun Microsystems, Inc.
# All rights reserved.
#
#ident  "@(#)dsclinfo 1.1     05/06/22 SMI"
#
# NWS DataServices within SunCluster 'clinfo' script
#
# Description:
#
# This script is called to change the behavior of /usr/sbin/clinfo so that its
# return code offers additional functionality.

# Usage:
#
# /usr/opt/SUNWesm/cluster/sbin/reconfig { start | stop } diskgroup
#
# Configuration:
#
# The script is invoked by the following run-level scripts, to determine if
# the current Solaris node is a Sun Cluster node, and if so what its number is.
#
# Exit status:
#
# -1 - error
#  0 - Non-Sun Cluster node
# >0 - Sun Cluster node number
/usr/sbin/clinfo -n 2>/dev/null || echo 0
