#!/bin/sh

#
# Include the functions declared in the /etc/init.d/functions file
#
ROOT="/usr/sbin"
source /etc/rc.d/functions

case "$1" in
        start)
                echon "Starting rpc portmap......"
                loadproc /sbin/rpc.portmap

                echon "Starting rpc mountd......."
                loadproc $ROOT/rpc.mountd
		
		echon "Starting rpc network filesystem daemon...."
		loadproc $ROOT/rpc.nfsd
                ;;

        stop)
                echon "Stopping rpc portmap......"
                killproc rpc.portmap

                echon "Stopping rpc mountd......."
                killproc rpc.mountd
		
		echon "Stopping rpc network filesystem daemon...."
		killproc rpc.nfsd
	        ;;
	reload)	
		echon "Reloading rpc services ...."
		evaluate_retval
	        ;;

        restart)
                $0 stop
                /bin/sleep 1
                $0 start
                ;;
        status)
                statusproc rpc.mountd
                statusproc rpc.nfsd
                ;;
        *)
                echo "Usage: $0 {start|stop|restart|reload|status}"
                exit 1
        ;;

esac


# End /etc/init.d/sysklogd
