#! /bin/sh
#
# rpc		This shell script takes care of starting and stopping
#		the NFS services. Later we might add NIS too.
#
# Version:	@(#) /etc/init.d/nfs 1.01 26-Oct-1993
#
# Author:	Miquel van Smoorenburg, <miquels@drinkel.nl.mugnet.org>
#

  # Source function library.
  . /etc/init.d/functions

  # See how we were called.
  case "$1" in
    start)
	# Start daemons.
	echo -n "Starting NFS services "
	daemon /usr/sbin/rpc.mountd
	daemon /usr/sbin/rpc.nfsd
	echo
	;;
    stop)
	# Stop the daemons.
	if [ "$previous" = 3 ]
	then
		echo -n "Shutting down NFS services "
		killproc rpc.mountd
		killproc rpc.nfsd
		echo
	fi
	;;
    *)
	# Oops someone made a typo.
	echo "Usage: /etc/init.d/nfs {start|stop}"
	exit 1
  esac

  exit 0
