#!/bin/ksh # IBM_PROLOG_BEGIN_TAG # This is an automatically generated prolog. # # 61haes_r714 src/43haes/usr/sbin/cluster/cspoc/utilities/clchkspuser.sh 1.2 # # Licensed Materials - Property of IBM # # COPYRIGHT International Business Machines Corp. 1998,2004 # All Rights Reserved # # US Government Users Restricted Rights - Use, duplication or # disclosure restricted by GSA ADP Schedule Contract with IBM Corp. # # IBM_PROLOG_END_TAG # @(#)09 1.2 src/43haes/usr/sbin/cluster/cspoc/utilities/clchkspuser.sh, hacmp.cspoc, 61haes_r714 2/20/04 10:53:09 # ############################################################################### # # Name: # clchkspuser.sh # # Description: # Determines if this node is part of an SP. If it is, it determines if the # user has usrmgmt_config set to 'true'. Displays 'true' if it is set, and # false for all other cases. # # Usage: clchkspuser # # Return Values: # 0 Success # 1 Failure # ############################################################################### function leave { print $1 exit $2 } [[ -f /usr/lpp/ssp/bin/SDRGetObjects ]] && { # We are on an SP. Get the usrmgmt_config value. VALUE=$(/usr/lpp/ssp/bin/SDRGetObjects -x SP usermgmt_config) [[ "$VALUE" = *true* ]] && leave "true" 0 } leave "false" 0