]>
Commit | Line | Data |
---|---|---|
cf3e5788 AZ |
1 | <?xml version='1.0'?> <!--*-nxml-*--> |
2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" | |
3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> | |
db9ecf05 | 4 | <!-- SPDX-License-Identifier: LGPL-2.1-or-later --> |
cf3e5788 AZ |
5 | |
6 | <refentry id="oomd.conf" conditional='ENABLE_OOMD' | |
7 | xmlns:xi="http://www.w3.org/2001/XInclude"> | |
8 | <refentryinfo> | |
9 | <title>oomd.conf</title> | |
10 | <productname>systemd</productname> | |
11 | </refentryinfo> | |
12 | ||
13 | <refmeta> | |
14 | <refentrytitle>oomd.conf</refentrytitle> | |
15 | <manvolnum>5</manvolnum> | |
16 | </refmeta> | |
17 | ||
18 | <refnamediv> | |
19 | <refname>oomd.conf</refname> | |
20 | <refname>oomd.conf.d</refname> | |
21 | <refpurpose>Global <command>systemd-oomd</command> configuration files</refpurpose> | |
22 | </refnamediv> | |
23 | ||
24 | <refsynopsisdiv> | |
25 | <para><filename>/etc/systemd/oomd.conf</filename></para> | |
26 | <para><filename>/etc/systemd/oomd.conf.d/*.conf</filename></para> | |
27 | <para><filename>/usr/lib/systemd/oomd.conf.d/*.conf</filename></para> | |
28 | </refsynopsisdiv> | |
29 | ||
30 | <refsect1> | |
31 | <title>Description</title> | |
32 | ||
33 | <para>These files configure the various parameters of the | |
34 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry> userspace | |
35 | out-of-memory (OOM) killer, | |
36 | <citerefentry><refentrytitle>systemd-oomd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
37 | See <citerefentry><refentrytitle>systemd.syntax</refentrytitle><manvolnum>7</manvolnum></citerefentry> | |
38 | for a general description of the syntax.</para> | |
39 | ||
40 | </refsect1> | |
41 | ||
42 | <xi:include href="standard-conf.xml" xpointer="main-conf" /> | |
43 | ||
44 | <refsect1> | |
45 | <title>[OOM] Section Options</title> | |
46 | ||
47 | <para>The following options are available in the [OOM] section:</para> | |
48 | ||
49 | <variablelist class='config-directives'> | |
50 | <varlistentry> | |
d06e7fb5 LP |
51 | <term><varname>SwapUsedLimit=</varname></term> |
52 | ||
53 | <listitem><para>Sets the limit for swap usage on the system before <command>systemd-oomd</command> | |
54 | will take action. If the fraction of swap used on the system is more than what is defined here, | |
55 | <command>systemd-oomd</command> will act on eligible descendant control groups, starting from the | |
56 | ones with the highest swap usage to the lowest swap usage. Which control groups are monitored and | |
57 | what action gets taken depends on what the unit has configured for | |
58 | <varname>ManagedOOMSwap=</varname>. Takes a value specified in percent (when suffixed with "%"), | |
59 | permille ("‰") or permyriad ("‱"), between 0% and 100%, inclusive. Defaults to 90%.</para></listitem> | |
cf3e5788 AZ |
60 | </varlistentry> |
61 | ||
62 | <varlistentry> | |
0a9f9344 | 63 | <term><varname>DefaultMemoryPressureLimit=</varname></term> |
cf3e5788 | 64 | |
d06e7fb5 LP |
65 | <listitem><para>Sets the limit for memory pressure on the unit's control group before |
66 | <command>systemd-oomd</command> will take action. A unit can override this value with | |
67 | <varname>ManagedOOMMemoryPressureLimit=</varname>. The memory pressure for this property represents | |
68 | the fraction of time in a 10 second window in which all tasks in the control group were delayed. For | |
69 | each monitored control group, if the memory pressure on that control group exceeds the limit set for | |
70 | longer than the duration set by <varname>DefaultMemoryPressureDurationSec=</varname>, | |
71 | <command>systemd-oomd</command> will act on eligible descendant control groups, starting from the | |
72 | ones with the most reclaim activity to the least reclaim activity. Which control groups are monitored | |
73 | and what action gets taken depends on what the unit has configured for | |
74 | <varname>ManagedOOMMemoryPressure=</varname>. Takes a fraction specified in the same way as | |
75 | <varname>SwapUsedLimit=</varname> above. Defaults to 60%.</para></listitem> | |
cf3e5788 AZ |
76 | </varlistentry> |
77 | ||
c20aa7b1 AZ |
78 | <varlistentry> |
79 | <term><varname>DefaultMemoryPressureDurationSec=</varname></term> | |
80 | ||
d06e7fb5 LP |
81 | <listitem><para>Sets the amount of time a unit's control group needs to have exceeded memory pressure |
82 | limits before <command>systemd-oomd</command> will take action. Memory pressure limits are defined by | |
0a9f9344 | 83 | <varname>DefaultMemoryPressureLimit=</varname> and <varname>ManagedOOMMemoryPressureLimit=</varname>. |
c20aa7b1 AZ |
84 | Defaults to 30 seconds when this property is unset or set to 0.</para></listitem> |
85 | </varlistentry> | |
86 | ||
cf3e5788 AZ |
87 | </variablelist> |
88 | </refsect1> | |
89 | ||
90 | <refsect1> | |
91 | <title>See Also</title> | |
92 | <para> | |
93 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
94 | <citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
95 | <citerefentry><refentrytitle>systemd-oomd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, | |
96 | <citerefentry><refentrytitle>oomctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
97 | </para> | |
98 | </refsect1> | |
99 | ||
100 | </refentry> |