]>
Commit | Line | Data |
---|---|---|
1 | <?xml version="1.0"?> | |
2 | <!--*-nxml-*--> | |
3 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" | |
4 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> | |
5 | <!-- SPDX-License-Identifier: LGPL-2.1+ --> | |
6 | <refentry id="systemd-sysctl.service" | |
7 | xmlns:xi="http://www.w3.org/2001/XInclude"> | |
8 | ||
9 | <refentryinfo> | |
10 | <title>systemd-sysctl.service</title> | |
11 | <productname>systemd</productname> | |
12 | </refentryinfo> | |
13 | ||
14 | <refmeta> | |
15 | <refentrytitle>systemd-sysctl.service</refentrytitle> | |
16 | <manvolnum>8</manvolnum> | |
17 | </refmeta> | |
18 | ||
19 | <refnamediv> | |
20 | <refname>systemd-sysctl.service</refname> | |
21 | <refname>systemd-sysctl</refname> | |
22 | <refpurpose>Configure kernel parameters at boot</refpurpose> | |
23 | </refnamediv> | |
24 | ||
25 | <refsynopsisdiv> | |
26 | <cmdsynopsis> | |
27 | <command>/usr/lib/systemd/systemd-sysctl</command> | |
28 | <arg choice="opt" rep="repeat">OPTIONS</arg> | |
29 | <arg choice="opt" rep="repeat"><replaceable>CONFIGFILE</replaceable></arg> | |
30 | </cmdsynopsis> | |
31 | <para><filename>systemd-sysctl.service</filename></para> | |
32 | </refsynopsisdiv> | |
33 | ||
34 | <refsect1> | |
35 | <title>Description</title> | |
36 | ||
37 | <para><filename>systemd-sysctl.service</filename> is an early boot | |
38 | service that configures | |
39 | <citerefentry project='man-pages'><refentrytitle>sysctl</refentrytitle><manvolnum>8</manvolnum></citerefentry> | |
40 | kernel parameters by invoking <command>/usr/lib/systemd/systemd-sysctl</command>.</para> | |
41 | ||
42 | <para>When invoked with no arguments, <command>/usr/lib/systemd/systemd-sysctl</command> applies | |
43 | all directives from configuration files listed in | |
44 | <citerefentry><refentrytitle>sysctl.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>. | |
45 | If one or more filenames are passed on the command line, only the directives in these files are | |
46 | applied.</para> | |
47 | ||
48 | <para>In addition, <option>--prefix=</option> option may be used to limit which sysctl | |
49 | settings are applied.</para> | |
50 | ||
51 | <para>See | |
52 | <citerefentry><refentrytitle>sysctl.d</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
53 | for information about the configuration of sysctl settings. After sysctl configuration is | |
54 | changed on disk, it must be written to the files in <filename>/proc/sys</filename> before it | |
55 | takes effect. It is possible to update specific settings, or simply to reload all configuration, | |
56 | see Examples below.</para> | |
57 | </refsect1> | |
58 | ||
59 | <refsect1><title>Options</title> | |
60 | <variablelist> | |
61 | <varlistentry id='prefix'> | |
62 | <term><option>--prefix=</option></term> | |
63 | <listitem> | |
64 | <para>Only apply rules with the specified prefix.</para> | |
65 | </listitem> | |
66 | </varlistentry> | |
67 | ||
68 | <xi:include href="standard-options.xml" xpointer="cat-config" /> | |
69 | <xi:include href="standard-options.xml" xpointer="no-pager" /> | |
70 | <xi:include href="standard-options.xml" xpointer="help" /> | |
71 | <xi:include href="standard-options.xml" xpointer="version" /> | |
72 | ||
73 | </variablelist> | |
74 | </refsect1> | |
75 | ||
76 | <refsect1> | |
77 | <title>Examples</title> | |
78 | ||
79 | <example> | |
80 | <title>Reset all sysctl settings</title> | |
81 | ||
82 | <programlisting>systemctl restart systemd-sysctl</programlisting> | |
83 | </example> | |
84 | ||
85 | <example> | |
86 | <title>View coredump handler configuration</title> | |
87 | ||
88 | <programlisting># sysctl kernel.core_pattern | |
89 | kernel.core_pattern = |/usr/libexec/abrt-hook-ccpp %s %c %p %u %g %t %P %I | |
90 | </programlisting> | |
91 | </example> | |
92 | ||
93 | <example> | |
94 | <title>Update coredump handler configuration</title> | |
95 | ||
96 | <programlisting># /usr/lib/systemd/systemd-sysctl --prefix kernel.core_pattern</programlisting> | |
97 | ||
98 | <para>This searches all the directories listed in | |
99 | <citerefentry><refentrytitle>sysctl.d</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
100 | for configuration files and writes <filename>/proc/sys/kernel/core_pattern</filename>.</para> | |
101 | </example> | |
102 | ||
103 | <example> | |
104 | <title>Update coredump handler configuration according to a specific file</title> | |
105 | ||
106 | <programlisting># /usr/lib/systemd/systemd-sysctl 50-coredump.conf</programlisting> | |
107 | ||
108 | <para>This applies all the settings found in <filename>50-coredump.conf</filename>. | |
109 | Either <filename>/etc/sysctl.d/50-coredump.conf</filename>, or | |
110 | <filename>/run/sysctl.d/50-coredump.conf</filename>, or | |
111 | <filename>/usr/lib/sysctl.d/50-coredump.conf</filename> will be used, in the order | |
112 | of preference.</para> | |
113 | </example> | |
114 | ||
115 | <para>See | |
116 | <citerefentry project='man-pages'><refentrytitle>sysctl</refentrytitle><manvolnum>8</manvolnum></citerefentry> | |
117 | for various ways to directly apply sysctl settings.</para> | |
118 | </refsect1> | |
119 | ||
120 | <refsect1> | |
121 | <title>See Also</title> | |
122 | <para> | |
123 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
124 | <citerefentry><refentrytitle>sysctl.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
125 | <citerefentry project='man-pages'><refentrytitle>sysctl</refentrytitle><manvolnum>8</manvolnum></citerefentry>, | |
126 | </para> | |
127 | </refsect1> | |
128 | ||
129 | </refentry> |