3 # vprocunhide sets vserver related attributes for /proc
5 # chkconfig: 2345 26 74
6 # description: Makes some /proc entries visibly for vservers
8 # Source function library.
9 . /etc/rc.d/init.d/functions
11 [ -n "$UTIL_VSERVER_VARS" ] || UTIL_VSERVER_VARS=/usr/lib/util-vserver/util-vserver-vars
12 if [ ! -e "$UTIL_VSERVER_VARS" ] ; then
13 echo "Can not find util-vserver installation (the file '$UTIL_VSERVER_VARS' would be expected); aborting..." >&2
16 . "$UTIL_VSERVER_VARS"
20 if [ ! -d /proc/virtual ]; then
21 show "Fixing vservers /proc entries visibility. kernel not capable"
26 show "Fixing vservers /proc entries visibility"
36 [ "$RETVAL" -eq 0 ] && touch /var/lock/subsys/vprocunhide
39 show "Stopping vservers /proc entries visibility"
41 rm -f /var/lock/subsys/vprocunhide
49 if [ -f /var/lock/subsys/vprocunhide ] ; then
50 echo "vservers /proc entries were fixed"
52 echo "vservers /proc entries were not fixed"
56 echo "Usage: $0 {start|stop|reload|restart|status}"
63 # This must be last line !
64 # vi:syntax=sh:tw=78:ts=4:sw=4