2000-03-10 14:53:23 +03:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
2000-08-22 03:31:24 +04:00
|
|
|
# $NetBSD: sysctl,v 1.9 2000/08/21 23:31:24 lukem Exp $
|
2000-03-10 14:53:23 +03:00
|
|
|
#
|
|
|
|
|
|
|
|
# PROVIDE: sysctl
|
2000-08-22 03:31:24 +04:00
|
|
|
# REQUIRE: root ipfilter ipsec
|
2000-03-10 14:53:23 +03:00
|
|
|
|
|
|
|
. /etc/rc.subr
|
|
|
|
|
|
|
|
name="sysctl"
|
|
|
|
start_cmd="sysctl_start"
|
|
|
|
stop_cmd=":"
|
|
|
|
|
|
|
|
sysctl_start()
|
|
|
|
{
|
2000-04-10 01:00:04 +04:00
|
|
|
if [ -n "$defcorename" ]; then
|
|
|
|
cat <<__EOF__
|
|
|
|
*** WARNING: /etc/rc.conf \$defcorename setting is obsolete. Please
|
|
|
|
*** set kern.defcorename in /etc/sysctl.conf
|
|
|
|
__EOF__
|
2000-05-07 23:03:25 +04:00
|
|
|
sysctl -w kern.defcorename=$defcorename
|
2000-04-10 01:00:04 +04:00
|
|
|
fi
|
|
|
|
|
2000-05-07 23:03:25 +04:00
|
|
|
if [ -n "$nfsiod_flags" ]; then
|
2000-04-16 01:14:48 +04:00
|
|
|
cat <<__EOF__
|
|
|
|
*** WARNING: /etc/rc.conf \$nfsiod_flags setting is obsolete. Please
|
2000-05-07 23:03:25 +04:00
|
|
|
*** remove it. If it was set to other than the default of "-n 4", then
|
2000-05-07 06:04:20 +04:00
|
|
|
*** set vfs.nfs.iothreads in /etc/sysctl.conf
|
2000-04-16 01:14:48 +04:00
|
|
|
__EOF__
|
|
|
|
fi
|
|
|
|
|
2000-04-09 03:02:53 +04:00
|
|
|
if [ -r /etc/sysctl.conf ]; then
|
|
|
|
echo "Setting sysctl variables:"
|
|
|
|
sysctl -f /etc/sysctl.conf
|
2000-03-10 14:53:23 +03:00
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
2000-05-13 12:45:06 +04:00
|
|
|
load_rc_config $name
|
2000-03-10 14:53:23 +03:00
|
|
|
run_rc_command "$1"
|