1SYSCTL(8) SYSCTL(8)
2
3
4
6 sysctl - configure kernel parameters at runtime
7
9 sysctl [-n] [-e] variable ...
10 sysctl [-n] [-e] [-q] -w variable=value ...
11 sysctl [-n] [-e] [-q] -p [filename]...
12 sysctl [-n] [-e] [-q] --system
13 sysctl [-n] [-e] -a
14 sysctl [-n] [-e] -A
15
17 sysctl is used to modify kernel parameters at runtime. The parameters
18 available are those listed under /proc/sys/. Procfs is required for
19 sysctl(8) support in Linux. You can use sysctl(8) to both read and
20 write sysctl data.
21
23 variable
24 The name of a key to read from. An example is kernel.ostype.
25 The '/' separator is also accepted in place of a '.'.
26
27 variable=value
28 To set a key, use the form variable=value, where variable is the
29 key and value is the value to set it to. If the value contains
30 quotes or characters which are parsed by the shell, you may need
31 to enclose the value in double quotes. This requires the -w
32 parameter to use.
33
34 -n Use this option to disable printing of the key name when printā
35 ing values.
36
37 -e Use this option to ignore errors about unknown keys.
38
39 -N Use this option to only print the names. It may be useful with
40 shells that have programmable completion.
41
42 -q Use this option to not display the values set to stdout.
43
44 -w Use this option when you want to change a sysctl setting.
45
46 -p Load in sysctl settings from the file(s) specified or
47 /etc/sysctl.conf if none given. Specifying - as filename means
48 reading data from standard input.
49
50 --system
51 Load settings from all system configuration files. Files are
52 read from directories in the following list in given order from
53 top to bottom. Once a file of a given filename is loaded, any
54 file of the same name in subsequent directories is ignored.
55 /run/sysctl.d/*.conf
56 /etc/sysctl.d/*.conf
57 /usr/local/lib/sysctl.d/*.conf
58 /usr/lib/sysctl.d/*.conf
59 /lib/sysctl.d/*.conf
60 /etc/sysctl.conf
61
62 -a Display all values currently available.
63
64 -A Same as -a
65
67 /sbin/sysctl -a
68
69 /sbin/sysctl -n kernel.hostname
70
71 /sbin/sysctl -w kernel.domainname="example.com"
72
73 /sbin/sysctl -p /etc/sysctl.conf
74
76 Please note that modules loaded after sysctl is run may override the
77 settings (example: sunrpc.* settings are overridden when the sunrpc
78 module is loaded). This may cause some confusion during boot when the
79 settings in sysctl.conf may be overriden. To prevent such a situation,
80 sysctl must be run after the particular module is loaded (e.g., from
81 /etc/rc.d/rc.local or by using the install directive in modprobe.conf)
82
84 /proc/sys /etc/sysctl.conf
85
87 sysctl.conf(5), modprobe.conf(5)
88
90 George Staikos, <staikos@0wned.org>
91
92
93
94
95 21 Sep 1999 SYSCTL(8)