#!/bin/ksh
# set -x
#
# This is the post-patch section
#

echo "========================================================================="
echo

if [ -r /etc/opt/SUNWssm/ENV ]
then
   echo "PATCH_LEVEL=2" >> /etc/opt/SUNWssm/ENV
else
   echo "SUNWssm environment file is missing. This indicates a errorcondition"
   echo "in SUNWssm, but it won't affect the installation of this patch but"
   echo "not being able to update this file with the entry:"
   echo ""
   echo "PATCH_LEVEL=2"
   echo ""
   echo "If you have moved this file to another location, please include"
   echo "the line above, for proper functionality."
fi

if [ -f "/tmp/SUNWssm_RESTART.$PPID" ]
then
   echo "Restarting SUNWssm."
   /opt/SUNWssm/sbin/Boot && sleep 20
else
   echo "Warning! You have to activate SUNWssm manually."
fi
