
indx=`expr $indx + 1`
tIP=`printf "%s.%d" ${IP_DOMAIN} ${indx}`
host ${tIP} > /dev/null 2>/dev/null
done
echo "${fhost} ${tIP}"
b) prep_stor_host.sh – adds/verifies each of the host's HBA, then presents the LUN
used for RHEV to all the host's HBAs
#!/bin/bash
#source variables
if [[ -x varDefs.sh ]]
then
source varDefs.sh
elif [[ -x /root/varDefs.sh ]]
then
source /root/varDefs.sh
elif [[ -x /root/resources/varDefs.sh ]]
then
source /root/resources/varDefs.sh
elif [[ -x /root/distro/resources/varDefs.sh ]]
then
source /root/distro/resources/varDefs.sh
else
echo "didn't find a varDefs.sh file"
fi
# Confirm that a parameter was passed
if [[ $# -ne 1 ]]
then
echo "Usage: $0 <profile name>\n"
exit -1
fi
PNAME=$1
# Confirm that the passed is an existing profile
if [[ ! `vcmcommand --vcmurl //${LOGIN}:${VCM_PW}@${VCM_IP} show profile | grep $
{PNAME}` ]]
then
echo ${PNAME} " is not an existing profile!"
exit -2
fi
#Add the HBAs of this host to the MSA storage array
if [[ `sacommand --saurl //${MSA_USER}:${MSA_PW}@${MSA_IP} show hosts | grep $
{PNAME}_` ]]
then
113 www.redhat.com
Komentarze do niniejszej Instrukcji