summaryrefslogtreecommitdiff
path: root/etc/rc.local
blob: d9c10fbbe8f4f7f10b7fc82c9c295c6b1dada2d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#	$OpenBSD: rc.local,v 1.35 2004/04/07 19:23:39 david Exp $

# site-specific startup actions, daemons, and other things which
# can be done AFTER your system goes into securemode.  For actions
# which should be done BEFORE your system has gone into securemode
# please see /etc/rc.securelevel

# site-specific startup actions, daemons which can be run
# Add your local changes additions to this file

echo -n 'starting local daemons:'

# run ntpdate prior to ntpd
if [ $securelevel -le 1 -a X"${ntpdate_flags}" != X"NO" \
    -a -x /usr/local/sbin/ntpdate ]; then
	echo -n ' ntpdate'
	/usr/local/sbin/ntpdate -b ${ntpdate_flags} >/dev/null
fi

if [ X"${ntpd}" == X"YES" -a -x /usr/local/sbin/ntpd \
    -a -e /etc/ntp.conf ]; then
	ntpd_flags="-p /var/run/ntpd.pid"
	if [ $securelevel -ge 1 ]; then
		ntpd_flags="${ntpd_flags} -x"
	fi
	echo -n ' ntpd';       /usr/local/sbin/ntpd ${ntpd_flags}
fi

if [ -x /usr/local/sbin/cfsd ]; then
	if ps auxc | grep -q '^ *root .* mountd$'; then
		echo -n ' cfsd';        /usr/local/sbin/cfsd >/dev/null 2>&1
		mount -o port=3049,nfsv2,intr localhost:/null /crypt
	else
		echo -n ' cfsd (failed, no mountd running)'
	fi
fi

#if [ -x /usr/local/sbin/snmpd ]; then
#	echo -n ' snmpd';	/usr/local/sbin/snmpd
#fi

echo '.'

# Netatalk stuff
#if [ -f /etc/netatalk/rc.atalk ]; then
#	. /etc/netatalk/rc.atalk
#fi