#
# CDDL HEADER START
#
# The contents of this file are subject to the terms of the
# Common Development and Distribution License (the "License").
# You may not use this file except in compliance with the License.
#
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
# See the License for the specific language governing permissions
# and limitations under the License.
#
# When distributing Covered Code, include this CDDL HEADER in each
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
# If applicable, add the following below this CDDL HEADER, with the
# fields enclosed by brackets "[]" replaced with your own identifying
# information: Portions Copyright [yyyy] [name of copyright owner]
#
# CDDL HEADER END
#
#
# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
#
# r.manifest - smf(5) manifest remove class action script
#
# number of seconds to wait before killing processes
STOP_DELAY=60
#
# Helper function. Delete the manifest hash value.
# Arguments: $1: manifest file.
#
{
if [ "$?" != "0" ];then
# this Solaris release doesn't have delhash command
fi
fi
}
#
# Helper function. Handle services deathrow file.
# Arguments: $1:manifest file, $2:package name.
#
{
# remove alternate root from manifest path
'{ print substr($2, length($1)+1); }'`
#
# Services deathrow file handling, file format:
# <fmri>< ><manifest file>< ><package name>
# (field separator is a space character)
#
# Manifest file could be from another Solaris version, bypass the
# the service bundle and validation (we only need the fmris list).
# Calling svccfg inventory with SVCCFG_NOVALIDATE=1 is safe because
# there is no access to the alternate repository.
#
# add to services deathrow file
echo ${fmri} ${manifest} $2 >> ${DEATHROW_FILE}
done
}
svcinst=$1
wait_time=$2
while [ ${nsec:=0} -lt $wait_time ]; do
return 0
fi
fi
done
return 1
}
#
# We can't safely disable the service in this case.
#
else
#
# We can verify if the service is disabled prior to
# removal.
#
fi
fi
while read mfst; do
if [ "$smf_alive" = "yes" ]; then
else
# deathrow handling
fi
done
exit 0