sysctl revision 244198
145096Simp#!/bin/sh 245096Simp# 350472Speter# $FreeBSD: head/etc/rc.d/sysctl 244198 2012-12-13 23:32:47Z delphij $ 466830Sobrien# 564446Schris 6100280Sgordon# PROVIDE: sysctl 766830Sobrien 8100280Sgordon. /etc/rc.subr 992516Sdougb 10100280Sgordonname="sysctl" 11244198Sdelphijcommand="/sbin/sysctl" 12100280Sgordonstop_cmd=":" 13124625Smtmstart_cmd="sysctl_start" 14124625Smtmreload_cmd="sysctl_start" 15124625Smtmlastload_cmd="sysctl_start last" 16124622Smtmextra_commands="reload lastload" 17100280Sgordon 18181070Sjhbsysctl_start() 19181070Sjhb{ 20244198Sdelphij case $1 in 21244198Sdelphij last) 22244198Sdelphij command_args="-i -f" 23244198Sdelphij ;; 24244198Sdelphij *) 25244198Sdelphij command_args="-f" 26244198Sdelphij ;; 27244198Sdelphij esac 28181070Sjhb 29244198Sdelphij for _f in /etc/sysctl.conf /etc/sysctl.conf.local; do 30244198Sdelphij [ -r ${_f} ] && ${command} ${command_args} ${_f} > /dev/null 31244198Sdelphij done 32181070Sjhb} 33181070Sjhb 34100280Sgordonload_rc_config $name 35100280Sgordonrun_rc_command "$1" 36