summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/defaults/rc.conf4
-rwxr-xr-xetc/rc.d/rctl4
-rw-r--r--share/man/man5/rc.conf.522
3 files changed, 27 insertions, 3 deletions
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf
index 1ee6324..5e6b740 100644
--- a/etc/defaults/rc.conf
+++ b/etc/defaults/rc.conf
@@ -663,6 +663,10 @@ newsyslog_flags="-CN" # Newsyslog flags to create marked files
mixer_enable="YES" # Run the sound mixer.
opensm_enable="NO" # Opensm(8) for infiniband devices defaults to off
+# rctl(8) requires kernel options RACCT and RCTL
+rctl_enable="NO" # Load rctl(8) rules on boot
+rctl_rules="/etc/rctl.conf" # rctl(8) ruleset. See rctl.conf(5).
+
##############################################################
### Jail Configuration (see rc.conf(5) manual page) ##########
##############################################################
diff --git a/etc/rc.d/rctl b/etc/rc.d/rctl
index 4fa0579..567436b 100755
--- a/etc/rc.d/rctl
+++ b/etc/rc.d/rctl
@@ -15,7 +15,7 @@ stop_cmd="rctl_stop"
rctl_start()
{
- if [ -f /etc/rctl.conf ]; then
+ if [ -f ${rctl_rules} ]; then
while read var comments
do
case ${var} in
@@ -25,7 +25,7 @@ rctl_start()
rctl -a "${var}"
;;
esac
- done < /etc/rctl.conf
+ done < ${rctl_rules}
fi
}
diff --git a/share/man/man5/rc.conf.5 b/share/man/man5/rc.conf.5
index e89e729..50cf901 100644
--- a/share/man/man5/rc.conf.5
+++ b/share/man/man5/rc.conf.5
@@ -24,7 +24,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd December 25, 2013
+.Dd February 15, 2014
.Dt RC.CONF 5
.Os
.Sh NAME
@@ -4416,6 +4416,26 @@ interface if desired.
Defines the total number of seconds to wait for link to become usable,
polled at a 1-second interval.
The default is 30.
+.It Va rctl_enable
+.Pq Vt bool
+Set to
+.Dq Li YES
+to load
+.Xr rctl 8
+rules from the defined ruleset.
+The kernel must be built with
+.Cd "options RACCT"
+and
+.Cd "options RCTL" .
+.It Va rctl_rules
+.Pq Vt str
+Set to
+.Pa /etc/rctl.conf
+by default.
+This variables contains the
+.Xr rctl.conf 5
+ruleset to load for
+.Xr rctl 8 .
.El
.Sh FILES
.Bl -tag -width ".Pa /etc/defaults/rc.conf" -compact
OpenPOWER on IntegriCloud