opnsense-src/sbin/sysctl
Zhenlei Huang 8d5d7e2ba3 sysctl: Teach sysctl to attach and run itself in a jail
This allows the parent jail to retrieve or set kernel state when child
does not have sysctl(8) installed (e.g. light weighted OCI containers
or slim jails).

This is especially useful when manipulating jail prison or vnet sysctls.
For example, `sysctl -j foo -Ja` or `sysctl -j foo net.fibs=2`.

Reviewed by:	dfr (previous version), markj
MFC after:	1 week
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D48618

(cherry picked from commit 08aa7128dea4d14811ae4a0225d7c678869cfe62)
2025-02-06 23:38:04 +08:00
..
tests Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
Makefile sysctl: Teach sysctl to attach and run itself in a jail 2025-02-06 23:38:04 +08:00
Makefile.depend Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
sysctl.8 sysctl: Teach sysctl to attach and run itself in a jail 2025-02-06 23:38:04 +08:00
sysctl.c sysctl: Teach sysctl to attach and run itself in a jail 2025-02-06 23:38:04 +08:00
sysctl.conf Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00