1#!/bin/sh 2#
| 1#!/bin/sh 2#
|
3# $NetBSD: nfslocking,v 1.3 2000/05/13 08:45:07 lukem Exp $
| 3# $NetBSD: nfslocking,v 1.6 2002/03/24 15:52:41 lukem Exp $ 4# $FreeBSD: head/etc/rc.d/statd 98184 2002-06-13 22:14:37Z gordon $
|
4# 5 6# PROVIDE: nfslocking
| 5# 6 7# PROVIDE: nfslocking
|
7# REQUIRE: nfsd
| 8# REQUIRE: nfsserver nfsclient nfsd 9# BEFORE: DAEMON 10# KEYWORD: FreeBSD NetBSD
|
8 9. /etc/rc.subr 10 11arg=$1 12
| 11 12. /etc/rc.subr 13 14arg=$1 15
|
13start_precmd='checkyesno nfs_server || checkyesno nfs_client'
| 16case `${CMD_OSTYPE}` in 17FreeBSD) 18 RCVAR_SERVER="nfs_server_enable" 19 RCVAR_CLIENT="nfs_client_enable" 20 RCVAR_STATD="rpc_statd_enable" 21 RCVAR_LOCKD="rpc_lockd_enable" 22 ;; 23NetBSD) 24 RCVAR_SERVER="nfs_server" 25 RCVAR_CLIENT="nfs_client" 26 RCVAR_STATD="statd" 27 RCVAR_LOCKD="lockd" 28 ;; 29esac 30 31start_precmd="checkyesno ${RCVAR_SERVER} || checkyesno ${RCVAR_CLIENT} 32 [ -n "$rc_force" ]"
|
14stop_precmd=$start_precmd 15status_precmd=$start_precmd 16 17name="statd"
| 33stop_precmd=$start_precmd 34status_precmd=$start_precmd 35 36name="statd"
|
18rcvar=$name
| 37rcvar=${RCVAR_STATD}
|
19command="/usr/sbin/rpc.${name}" 20load_rc_config $name 21run_rc_command "$arg" 22 23name="lockd"
| 38command="/usr/sbin/rpc.${name}" 39load_rc_config $name 40run_rc_command "$arg" 41 42name="lockd"
|
24rcvar=$name
| 43rcvar=${RCVAR_LOCKD}
|
25command="/usr/sbin/rpc.${name}" 26load_rc_config $name 27run_rc_command "$arg"
| 44command="/usr/sbin/rpc.${name}" 45load_rc_config $name 46run_rc_command "$arg"
|