#!/bin/sh
#
#  $Id: //depot/prod/spinfs/rel2.5.4x/mgmt/src/scripts/poweroff#1 $
#
#  script to redirect callers of the poweroff command
#
#
echo "spinserver poweroff process started"

if [ ! "$1" ] ; then
	echo -n "ssid: "
	read ssid
else
	ssid="$1"
fi

if [ ! "$2" ] ; then
	echo -n "reason: "
	read reason
else
	reason="$2"
fi

spinsh -c spinserver shutdown -ssid \""$ssid"\" -shutdownreason \""$reason"\"

