mirror of
https://github.com/opnsense/src.git
synced 2026-05-16 02:59:48 -04:00
/etc/rc.d/securelevel is supposed to run /etc/rc.d/sysctl lastload
late at boot time to apply /etc/sysctl.conf settings that fail
to apply early. However, this does not work in default configuration
because of kern_securelevel_enable="NO" by default.
Add new script /etc/rc.d/sysctl_lastload that starts unconditionally.
Reported by: Marek Zarychta
(cherry picked from commit f4b38c360e)
18 lines
291 B
Bash
Executable file
18 lines
291 B
Bash
Executable file
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
# PROVIDE: sysctl_lastload
|
|
# REQUIRE: LOGIN
|
|
# BEFORE: jail
|
|
|
|
. /etc/rc.subr
|
|
|
|
name="sysctl_lastload"
|
|
desc="Last chance to set sysctl variables that failed the first time."
|
|
start_cmd="/etc/rc.d/sysctl lastload"
|
|
stop_cmd=":"
|
|
|
|
load_rc_config $name
|
|
run_rc_command "$1"
|