Project

General

Profile

Bug #1870 » 0003-rc.d-vkernel-pidfile-related-enhancements.patch

rumcic, 10/11/2010 09:07 AM

View differences:

etc/rc.d/vkernel
do
# Check if already running
eval pidfile="/var/run/vkernel.${_vkernel}.pid"
if [ -f "${_pidfile}" ]; then
echo
warn "Vkernel ${_vkernel} already running? (check ${pidfile})"
continue
if [ -f "${pidfile}" ]; then
eval pid=`cat ${pidfile}`
if [ ! -z "${pid}" -a ! -z "`ps axwwp ${pid} | grep -wE "^[ ]+${pid}" | grep -v grep | awk '{print $1}'`" ]; then
echo
warn "Vkernel ${_vkernel} already running? (check ${pidfile})"
continue
fi
fi
# Configure vkernel binary
(3-3/4)