#!/bin/ksh93 # IBM_PROLOG_BEGIN_TAG # This is an automatically generated prolog. # # 61haes_r714 src/43haes/usr/sbin/cluster/cspoc/utilities/clgetdisktype.sh 1.1 # # Licensed Materials - Property of IBM # # Restricted Materials of IBM # # COPYRIGHT International Business Machines Corp. 2003 # 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 # @(#)53 1.1 src/43haes/usr/sbin/cluster/cspoc/utilities/clgetdisktype.sh, hacmp.cspoc, 61haes_r714 11/20/03 17:34:24 # \$Id\$ # # Component: hacmp.cspoc # # Function: returns information on a given disk. Specifically: # - whether it can be used in a concurrent or enhanced # concurrent resource group # - its size # # Origins: 27 # # Arguments: hdisk name - e.g., hdisk3 # # Environment:None # ############################################################################# # # Pick up the given disk name # DISK=$1 if (( 1 == $(lquerypv -C $DISK) )) ; then # # The ones that LVM says are concurrent capable # CONCURRENT="C" ENHANCE_CONCURRENT_ONLY="N" elif [[ -x /usr/sbin/gsclvmd ]] ; then # # Otherwise, if the group services CLVM daemon is present, # pretty much anything can be used in a concurrent # volume group # CONCURRENT="C" ENHANCE_CONCURRENT_ONLY="Y" else # # Anything else can't be used in a concurrent volume group # CONCURRENT="N" ENHANCE_CONCURRENT_ONLY="N" fi # # Pick up the size of the disk while we're at it # integer DISK_SIZE=$(/usr/sbin/bootinfo -s $DISK) # # Pass back the collected data # echo $DISK:$CONCURRENT:$ENHANCE_CONCURRENT_ONLY:$DISK_SIZE return $?