]>
Commit | Line | Data |
---|---|---|
c91faef3 LP |
1 | <?xml version="1.0"?> |
2 | <!--*-nxml-*--> | |
3 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> | |
4 | <!-- | |
5 | This file is part of systemd. | |
6 | ||
7 | Copyright 2011 Lennart Poettering | |
8 | ||
9 | systemd is free software; you can redistribute it and/or modify it | |
5430f7f2 LP |
10 | under the terms of the GNU Lesser General Public License as published by |
11 | the Free Software Foundation; either version 2.1 of the License, or | |
c91faef3 LP |
12 | (at your option) any later version. |
13 | ||
14 | systemd is distributed in the hope that it will be useful, but | |
15 | WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
5430f7f2 | 17 | Lesser General Public License for more details. |
c91faef3 | 18 | |
5430f7f2 | 19 | You should have received a copy of the GNU Lesser General Public License |
c91faef3 LP |
20 | along with systemd; If not, see <http://www.gnu.org/licenses/>. |
21 | --> | |
22 | <refentry id="sysctl.d"> | |
23 | ||
24 | <refentryinfo> | |
25 | <title>sysctl.d</title> | |
26 | <productname>systemd</productname> | |
27 | ||
28 | <authorgroup> | |
29 | <author> | |
30 | <contrib>Developer</contrib> | |
31 | <firstname>Lennart</firstname> | |
32 | <surname>Poettering</surname> | |
33 | <email>lennart@poettering.net</email> | |
34 | </author> | |
35 | </authorgroup> | |
36 | </refentryinfo> | |
37 | ||
38 | <refmeta> | |
39 | <refentrytitle>sysctl.d</refentrytitle> | |
40 | <manvolnum>5</manvolnum> | |
41 | </refmeta> | |
42 | ||
43 | <refnamediv> | |
44 | <refname>sysctl.d</refname> | |
45 | <refpurpose>Configure kernel parameters at boot</refpurpose> | |
46 | </refnamediv> | |
47 | ||
48 | <refsynopsisdiv> | |
49 | <para><filename>/etc/sysctl.d/*.conf</filename></para> | |
db1413d7 | 50 | <para><filename>/run/sysctl.d/*.conf</filename></para> |
fc1a2e06 | 51 | <para><filename>/usr/lib/sysctl.d/*.conf</filename></para> |
c91faef3 LP |
52 | </refsynopsisdiv> |
53 | ||
54 | <refsect1> | |
55 | <title>Description</title> | |
56 | ||
95f77929 LP |
57 | <para><command>systemd</command> uses configuration |
58 | files from the above directories to configure | |
c91faef3 | 59 | <citerefentry><refentrytitle>sysctl</refentrytitle><manvolnum>8</manvolnum></citerefentry> |
95f77929 | 60 | kernel parameters during boot.</para> |
c91faef3 LP |
61 | </refsect1> |
62 | ||
63 | <refsect1> | |
64 | <title>Configuration Format</title> | |
65 | ||
95f77929 LP |
66 | <para>The configuration files contain a list of |
67 | variable assignments, separated by newlines. Empty | |
68 | lines and lines whose first non-whitespace character | |
69 | is # or ; are ignored.</para> | |
70 | ||
71 | <para>Note that both / and . are accepted as label | |
72 | separators within sysctl variable | |
73 | names. <literal>kernel.domainname=foo</literal> and | |
74 | <literal>kernel/domainname=foo</literal> hence are | |
75 | entirely equivalent.</para> | |
76 | ||
77 | <para>Each configuration file shall be named in the | |
78 | style of <filename><program>.conf</filename>. | |
79 | Files in <filename>/run/</filename> override files | |
80 | with the same name in <filename>/usr/lib/</filename>. | |
81 | Files in <filename>/etc</filename> override files with | |
82 | the same name in <filename>/run/</filename> and | |
83 | <filename>/usr/lib/</filename>. Packages should | |
84 | install their configuration files in | |
85 | <filename>/usr/lib/</filename>. Files in | |
86 | <filename>/etc/</filename> are reserved for the local | |
87 | administrator, who may use this logic to override the | |
88 | configuration installed by vendor packages. All | |
89 | configuration files are sorted by their name in | |
90 | alphabetical order, regardless in which of the | |
91 | directories they reside, to guarantee that a specific | |
92 | configuration file takes precedence over another file | |
93 | with an alphabetically earlier name, if both files | |
94 | contain the same variable setting.</para> | |
95 | ||
96 | <para>If the administrator wants to disable a | |
97 | configuration file supplied by the vendor the | |
98 | recommended way is to place a symlink to | |
99 | <filename>/dev/null</filename> in | |
100 | <filename>/etc/sysctl.d</filename> carrying with the | |
101 | same name.</para> | |
c91faef3 LP |
102 | </refsect1> |
103 | ||
104 | <refsect1> | |
105 | <title>Example</title> | |
106 | <example> | |
107 | <title>/etc/sysctl.d/domain-name.conf example:</title> | |
108 | ||
109 | <programlisting># Set kernel YP domain name | |
110 | kernel.domainname=example.com</programlisting> | |
111 | </example> | |
112 | </refsect1> | |
113 | ||
114 | <refsect1> | |
115 | <title>See Also</title> | |
116 | <para> | |
117 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
118 | <citerefentry><refentrytitle>sysctl</refentrytitle><manvolnum>8</manvolnum></citerefentry>, | |
119 | <citerefentry><refentrytitle>sysctl.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
120 | </para> | |
121 | </refsect1> | |
122 | ||
123 | </refentry> |