2008-12-09 20:40:25 +00:00
|
|
|
#!/bin/bash
|
2008-12-09 15:23:12 +00:00
|
|
|
# IBM(c) 2007 EPL license http://www.eclipse.org/legal/epl-v10.html
|
2008-12-09 20:40:25 +00:00
|
|
|
fwpref=${rvid_fwrev%%???}
|
|
|
|
fwver=${rvid_fwrev##????}
|
|
|
|
fwmaj=${fwver%%?}
|
|
|
|
if [ -z "$fwmaj" ]; then
|
|
|
|
echo "Unable to recognize AMM firmware revision"
|
|
|
|
exit 1
|
|
|
|
fi
|
2008-12-09 16:26:40 +00:00
|
|
|
mkdir -p /tmp/xcat
|
2008-12-09 15:23:12 +00:00
|
|
|
if [ ! -f /tmp/xcat/$rvid_server.remotekvm.jar ]; then
|
2008-12-09 20:55:31 +00:00
|
|
|
wget -O /tmp/xcat/$rvid_server.remotekvm.jar http://$rvid_server/private/remotekvm.jar >& /dev/null
|
2008-12-09 15:23:12 +00:00
|
|
|
fi
|
2008-12-09 20:40:25 +00:00
|
|
|
if [ $fwpref == 'BPET' ]; then
|
|
|
|
if [ $fwmaj -ge 46 ]; then
|
|
|
|
java -jar /tmp/xcat/$rvid_server.remotekvm.jar -s $rvid_server -r $rvid_authtoken -b $rvid_slot >& /dev/null
|
|
|
|
elif [ $fwmaj -ge 42 ]; then
|
2008-12-10 18:28:08 +00:00
|
|
|
echo "Unable to securely support $rvid_fwrev in an adequately secure manner, please upgrade to BPET46C or better"
|
|
|
|
exit 1
|
2008-12-09 20:40:25 +00:00
|
|
|
java -jar /tmp/xcat/$rvid_server.remotekvm.jar $rvid_server -rbs $rvid_authtoken -ba $rvid_ba -port $rvid_port >& /dev/null
|
|
|
|
else
|
|
|
|
echo "Unknown method for firmware $rvid_fwrev, ensure it is at least BPET42R";
|
|
|
|
fi
|
|
|
|
else
|
|
|
|
echo "Unknown semantics for $fwpref, trying a particular way, may not work."
|
|
|
|
java -jar /tmp/xcat/$rvid_server.remotekvm.jar $rvid_server -rbs $rvid_authtoken -ba $rvid_ba -b $rvid_slot >& /dev/null
|
|
|
|
fi
|
2008-12-09 15:23:12 +00:00
|
|
|
|
2008-12-09 20:40:25 +00:00
|
|
|
rm /tmp/xcat/$rvid_server.remotekvm.jar
|