3 # start/stop inetd super server.
5 # chkconfig: 2345 20 20
8 PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
9 if ! [ -x /usr/sbin/inetd ]; then
14 if grep -v "^ *#" /etc/inetd.conf | grep 'rpc/' >/dev/null; then
15 if ! [ -x /usr/bin/rpcinfo ]
18 echo "WARNING: rpcinfo not available - RPC services may be unavailable!"
19 echo " (Commenting out the rpc services in inetd.conf will"
20 echo " disable this message)"
22 elif ! /usr/bin/rpcinfo -u localhost portmapper >/dev/null 2>/dev/null
25 echo "WARNING: portmapper inactive - RPC services unavailable!"
26 echo " (Commenting out the rpc services in inetd.conf will"
27 echo " disable this message)"
36 echo -n "Starting internet superserver:"
37 echo -n " inetd" ; start-stop-daemon -S -q -p /var/run/inetd.pid -x /usr/sbin/inetd
41 echo -n "Stopping internet superserver:"
42 echo -n " inetd" ; start-stop-daemon -K -q -p /var/run/inetd.pid -x /usr/sbin/inetd
46 echo -n "Reloading internet superserver:"
48 start-stop-daemon -K -q -p /var/run/inetd.pid -s 1
55 echo -n "Restarting internet superserver:"
57 start-stop-daemon -K -q -p /var/run/inetd.pid
59 start-stop-daemon -S -q -p /var/run/inetd.pid -x /usr/sbin/inetd
63 echo "Usage: /etc/init.d/inetd {start|stop|reload|restart}"