Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > media > main-release > by-pkgid > 58225673a97ab16a684b7cd0c52f5aef > files > 33

heartbeat-2.0.8-5mdv2008.1.x86_64.rpm

#!/bin/sh
#
# $Id: ServeRAID.in,v 1.6 2006/08/14 09:37:21 andrew Exp $
# 
# Description:	wrapper of OCF RA ServeRAID, based on original heartbeat RA.
#		See OCF RA ServeRAID for more information.
#
# Author:	Xun Sun <xunsun@cn.ibm.com> 
# Support:      linux-ha@lists.linux-ha.org
# License:      GNU General Public License (GPL)
# Copyright:	(C) 2005 International Business Machines
#
# usage: ./ServeRAID <adapter> <MergeGroup#>  {start|stop|status}
#
#<adapter>:	Adapter number of the ServeRAID adapter 
#<MergeGroup#>:	MergeGroup # of the logical drive under consideration.
#
# An example usage in /etc/ha.d/haresources: 
#       node1  10.0.0.170 ServeRAID::1::1

# Source function library.
. /etc/ha.d/resource.d//hto-mapfuncs

usage() {
    echo "usage: $0 <serveraid#> <sharedmergegroup#> $LEGAL_ACTIONS"
    exit 1
}

if [ $# != 3 ]; then
    usage
fi

OCF_TYPE=ServeRAID
OCF_RESOURCE_INSTANCE=${OCF_TYPE}_$1
export OCF_TYPE OCF_RESOURCE_INSTANCE

OCF_RESKEY_serveraid=$1
OCF_RESKEY_mergegroup=$2
export OCF_RESKEY_mergegroup OCF_RESKEY_serveraid

ra_execocf $3