{"id":4477,"date":"2022-12-20T18:08:45","date_gmt":"2022-12-20T21:08:45","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/systemd-resourcecontrol-man5\/"},"modified":"2022-12-20T18:08:45","modified_gmt":"2022-12-20T21:08:45","slug":"systemd-resourcecontrol-man5","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/systemd-resourcecontrol-man5\/","title":{"rendered":"SYSTEMD.RESOURCE&minus;CONTROL (man5)"},"content":{"rendered":"<h1 align=\"center\">SYSTEMD.RESOURCE\u2212CONTROL<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#DESCRIPTION\">DESCRIPTION<\/a><br \/> <a href=\"#IMPLICIT DEPENDENCIES\">IMPLICIT DEPENDENCIES<\/a><br \/> <a href=\"#UNIFIED AND LEGACY CONTROL GROUP HIERARCHIES\">UNIFIED AND LEGACY CONTROL GROUP HIERARCHIES<\/a><br \/> <a href=\"#OPTIONS\">OPTIONS<\/a><br \/> <a href=\"#DEPRECATED OPTIONS\">DEPRECATED OPTIONS<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a><br \/> <a href=\"#NOTES\">NOTES<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">systemd.resource-control \u2212 Resource control unit settings<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>slice<\/i>.slice, <i>scope<\/i>.scope, <i>service<\/i>.service, <i>socket<\/i>.socket, <i>mount<\/i>.mount, <i>swap<\/i>.swap<\/p>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Unit configuration files for services, slices, scopes, sockets, mount points, and swap devices share a subset of configuration options for resource control of spawned processes. Internally, this relies on the Linux Control Groups (cgroups) kernel concept for organizing processes in a hierarchical tree of named groups for the purpose of resource management.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">This man page lists the configuration options shared by those six unit types. See <b>systemd.unit<\/b>(5) for the common options of all unit configuration files, and <b>systemd.slice<\/b>(5), <b>systemd.scope<\/b>(5), <b>systemd.service<\/b>(5), <b>systemd.socket<\/b>(5), <b>systemd.mount<\/b>(5), and <b>systemd.swap<\/b>(5) for more information on the specific unit configuration files. The resource control configuration options are configured in the [Slice], [Scope], [Service], [Socket], [Mount], or [Swap] sections, depending on the unit type.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">In addition, options which control resources available to programs <i>executed<\/i> by systemd are listed in <b>systemd.exec<\/b>(5). Those options complement options listed here.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">See the <b><font color=\"#0000FF\">New Control Group Interfaces<\/font><\/b> <small><font color=\"#000000\">[1]<\/font><\/small> <font color=\"#000000\">for an introduction on how to make use of resource control APIs from programs.<\/font><\/p>\n<h2>IMPLICIT DEPENDENCIES <a name=\"IMPLICIT DEPENDENCIES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">The following dependencies are implicitly added:<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">\u2022 Units with the <i>Slice=<\/i> setting set automatically acquire <i>Requires=<\/i> and <i>After=<\/i> dependencies on the specified slice unit.<\/font><\/p>\n<h2>UNIFIED AND LEGACY CONTROL GROUP HIERARCHIES <a name=\"UNIFIED AND LEGACY CONTROL GROUP HIERARCHIES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">The unified control group hierarchy is the new version of kernel control group interface, see<\/font> <b><font color=\"#0000FF\">Control Groups v2<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">. Depending on the resource type, there are differences in resource control capabilities. Also, because of interface changes, some resource types have separate set of options on the unified hierarchy.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">CPU<\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\"><i>CPUWeight=<\/i> and <i>StartupCPUWeight=<\/i> replace <i>CPUShares=<\/i> and <i>StartupCPUShares=<\/i>, respectively.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The &#8220;cpuacct&#8221; controller does not exist separately on the unified hierarchy.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">Memory<\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\"><i>MemoryMax=<\/i> replaces <i>MemoryLimit=<\/i>. <i>MemoryLow=<\/i> and <i>MemoryHigh=<\/i> are effective only on unified hierarchy.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">IO<\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">&#8220;IO&#8221;\u2212prefixed settings are a superset of and replace &#8220;BlockIO&#8221;\u2212prefixed ones. On unified hierarchy, IO resource control also applies to buffered writes.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">To ease the transition, there is best\u2212effort translation between the two versions of settings. For each controller, if any of the settings for the unified hierarchy are present, all settings for the legacy hierarchy are ignored. If the resulting settings are for the other type of hierarchy, the configurations are translated before application.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">Legacy control group hierarchy (see<\/font> <b><font color=\"#0000FF\">Control Groups version 1<\/font><\/b> <small><font color=\"#000000\">[3]<\/font><\/small> <font color=\"#000000\">), also called cgroup\u2212v1, doesn&#8217;t allow safe delegation of controllers to unprivileged processes. If the system uses the legacy control group hierarchy, resource control is disabled for the systemd user instance, see <b>systemd<\/b>(1).<\/font><\/p>\n<h2>OPTIONS <a name=\"OPTIONS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">Units of the types listed above can have settings for resource control configuration:<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>CPUAccounting=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turn on CPU usage accounting for this unit. Takes a boolean argument. Note that turning on CPU accounting for one unit will also implicitly turn it on for all units contained in the same slice and for all its parent slices and the units contained therein. The system default for this setting may be controlled with <i>DefaultCPUAccounting=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>CPUWeight=weight<\/i>, <i>StartupCPUWeight=weight<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Assign the specified CPU time weight to the processes executed, if the unified control group hierarchy is used on the system. These options take an integer value and control the &#8220;cpu.weight&#8221; control group attribute. The allowed range is 1 to 10000. Defaults to 100. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Control Groups v2<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">and<\/font> <b><font color=\"#0000FF\">CFS Scheduler<\/font><\/b> <small><font color=\"#000000\">[4]<\/font><\/small> <font color=\"#000000\">. The available CPU time is split up among all units within one slice relative to their CPU time weight.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">While <i>StartupCPUWeight=<\/i> only applies to the startup phase of the system, <i>CPUWeight=<\/i> applies to normal runtime of the system, and if the former is not set also to the startup phase. Using <i>StartupCPUWeight=<\/i> allows prioritizing specific services at boot\u2212up differently than during normal runtime.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings replace <i>CPUShares=<\/i> and <i>StartupCPUShares=<\/i>.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>CPUQuota=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Assign the specified CPU time quota to the processes executed. Takes a percentage value, suffixed with &#8220;%&#8221;. The percentage specifies how much CPU time the unit shall get at maximum, relative to the total CPU time available on one CPU. Use values > 100% for allotting CPU time on more than one CPU. This controls the &#8220;cpu.max&#8221; attribute on the unified control group hierarchy and &#8220;cpu.cfs_quota_us&#8221; on legacy. For details about these control group attributes, see<\/font> <b><font color=\"#0000FF\">Control Groups v2<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">and<\/font> <b><font color=\"#0000FF\">sched\u2212bwc.txt<\/font><\/b> <small><font color=\"#000000\">[5]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Example: <i>CPUQuota=20%<\/i> ensures that the executed processes will never get more than 20% CPU time on one CPU.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>CPUQuotaPeriodSec=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Assign the duration over which the CPU time quota specified by <i>CPUQuota=<\/i> is measured. Takes a time duration value in seconds, with an optional suffix such as &#8220;ms&#8221; for milliseconds (or &#8220;s&#8221; for seconds.) The default setting is 100ms. The period is clamped to the range supported by the kernel, which is [1ms, 1000ms]. Additionally, the period is adjusted up so that the quota interval is also at least 1ms. Setting <i>CPUQuotaPeriodSec=<\/i> to an empty value resets it to the default.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This controls the second field of &#8220;cpu.max&#8221; attribute on the unified control group hierarchy and &#8220;cpu.cfs_period_us&#8221; on legacy. For details about these control group attributes, see<\/font> <b><font color=\"#0000FF\">Control Groups v2<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">and<\/font> <b><font color=\"#0000FF\">CFS Scheduler<\/font><\/b> <small><font color=\"#000000\">[4]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Example: <i>CPUQuotaPeriodSec=10ms<\/i> to request that the CPU quota is measured in periods of 10ms.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>AllowedCPUs=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Restrict processes to be executed on specific CPUs. Takes a list of CPU indices or ranges separated by either whitespace or commas. CPU ranges are specified by the lower and upper CPU indices separated by a dash.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Setting <i>AllowedCPUs=<\/i> doesn&#8217;t guarantee that all of the CPUs will be used by the processes as it may be limited by parent units. The effective configuration is reported as <i>EffectiveCPUs=<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is supported only with the unified control group hierarchy.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>AllowedMemoryNodes=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Restrict processes to be executed on specific memory NUMA nodes. Takes a list of memory NUMA nodes indices or ranges separated by either whitespace or commas. Memory NUMA nodes ranges are specified by the lower and upper CPU indices separated by a dash.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Setting <i>AllowedMemoryNodes=<\/i> doesn&#8217;t guarantee that all of the memory NUMA nodes will be used by the processes as it may be limited by parent units. The effective configuration is reported as <i>EffectiveMemoryNodes=<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is supported only with the unified control group hierarchy.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemoryAccounting=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turn on process and kernel memory accounting for this unit. Takes a boolean argument. Note that turning on memory accounting for one unit will also implicitly turn it on for all units contained in the same slice and for all its parent slices and the units contained therein. The system default for this setting may be controlled with <i>DefaultMemoryAccounting=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemoryMin=bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the memory usage protection of the executed processes in this unit. If the memory usages of this unit and all its ancestors are below their minimum boundaries, this unit&#8217;s memory won&#8217;t be reclaimed.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the system. If assigned the special value &#8220;infinity&#8221;, all available memory is protected, which may be useful in order to always inherit all of the protection afforded by ancestors. This controls the &#8220;memory.min&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Memory Interface Files<\/font><\/b> <small><font color=\"#000000\">[6]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is supported only if the unified control group hierarchy is used and disables <i>MemoryLimit=<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Units may have their children use a default &#8220;memory.min&#8221; value by specifying <i>DefaultMemoryMin=<\/i>, which has the same semantics as <i>MemoryMin=<\/i>. This setting does not affect &#8220;memory.min&#8221; in the unit itself.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemoryLow=bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the best\u2212effort memory usage protection of the executed processes in this unit. If the memory usages of this unit and all its ancestors are below their low boundaries, this unit&#8217;s memory won&#8217;t be reclaimed as long as memory can be reclaimed from unprotected units.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the system. If assigned the special value &#8220;infinity&#8221;, all available memory is protected, which may be useful in order to always inherit all of the protection afforded by ancestors. This controls the &#8220;memory.low&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Memory Interface Files<\/font><\/b> <small><font color=\"#000000\">[6]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is supported only if the unified control group hierarchy is used and disables <i>MemoryLimit=<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Units may have their children use a default &#8220;memory.low&#8221; value by specifying <i>DefaultMemoryLow=<\/i>, which has the same semantics as <i>MemoryLow=<\/i>. This setting does not affect &#8220;memory.low&#8221; in the unit itself.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemoryHigh=bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the throttling limit on memory usage of the executed processes in this unit. Memory usage may go above the limit if unavoidable, but the processes are heavily slowed down and memory is taken away aggressively in such cases. This is the main mechanism to control memory usage of a unit.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the system. If assigned the special value &#8220;infinity&#8221;, no memory throttling is applied. This controls the &#8220;memory.high&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Memory Interface Files<\/font><\/b> <small><font color=\"#000000\">[6]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is supported only if the unified control group hierarchy is used and disables <i>MemoryLimit=<\/i>.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemoryMax=bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the absolute limit on memory usage of the executed processes in this unit. If memory usage cannot be contained under the limit, out\u2212of\u2212memory killer is invoked inside the unit. It is recommended to use <i>MemoryHigh=<\/i> as the main control mechanism and use <i>MemoryMax=<\/i> as the last line of defense.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the system. If assigned the special value &#8220;infinity&#8221;, no memory limit is applied. This controls the &#8220;memory.max&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Memory Interface Files<\/font><\/b> <small><font color=\"#000000\">[6]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting replaces <i>MemoryLimit=<\/i>.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemorySwapMax=bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the absolute limit on swap usage of the executed processes in this unit.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Takes a swap size in bytes. If the value is suffixed with K, M, G or T, the specified swap size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. If assigned the special value &#8220;infinity&#8221;, no swap limit is applied. This controls the &#8220;memory.swap.max&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Memory Interface Files<\/font><\/b> <small><font color=\"#000000\">[6]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is supported only if the unified control group hierarchy is used and disables <i>MemoryLimit=<\/i>.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>TasksAccounting=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turn on task accounting for this unit. Takes a boolean argument. If enabled, the system manager will keep track of the number of tasks in the unit. The number of tasks accounted this way includes both kernel threads and userspace processes, with each thread counting individually. Note that turning on tasks accounting for one unit will also implicitly turn it on for all units contained in the same slice and for all its parent slices and the units contained therein. The system default for this setting may be controlled with <i>DefaultTasksAccounting=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>TasksMax=N<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the maximum number of tasks that may be created in the unit. This ensures that the number of tasks accounted for the unit (see above) stays below a specific limit. This either takes an absolute number of tasks or a percentage value that is taken relative to the configured maximum number of tasks on the system. If assigned the special value &#8220;infinity&#8221;, no tasks limit is applied. This controls the &#8220;pids.max&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Process Number Controller<\/font><\/b> <small><font color=\"#000000\">[7]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The system default for this setting may be controlled with <i>DefaultTasksMax=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IOAccounting=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turn on Block I\/O accounting for this unit, if the unified control group hierarchy is used on the system. Takes a boolean argument. Note that turning on block I\/O accounting for one unit will also implicitly turn it on for all units contained in the same slice and all for its parent slices and the units contained therein. The system default for this setting may be controlled with <i>DefaultIOAccounting=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting replaces <i>BlockIOAccounting=<\/i> and disables settings prefixed with <i>BlockIO<\/i> or <i>StartupBlockIO<\/i>.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IOWeight=weight<\/i>, <i>StartupIOWeight=weight<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the default overall block I\/O weight for the executed processes, if the unified control group hierarchy is used on the system. Takes a single weight value (between 1 and 10000) to set the default block I\/O weight. This controls the &#8220;io.weight&#8221; control group attribute, which defaults to 100. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">IO Interface Files<\/font><\/b> <small><font color=\"#000000\">[8]<\/font><\/small> <font color=\"#000000\">. The available I\/O bandwidth is split up among all units within one slice relative to their block I\/O weight.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">While <i>StartupIOWeight=<\/i> only applies to the startup phase of the system, <i>IOWeight=<\/i> applies to the later runtime of the system, and if the former is not set also to the startup phase. This allows prioritizing specific services at boot\u2212up differently than during runtime.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings replace <i>BlockIOWeight=<\/i> and <i>StartupBlockIOWeight=<\/i> and disable settings prefixed with <i>BlockIO<\/i> or <i>StartupBlockIO<\/i>.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IODeviceWeight=device weight<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the per\u2212device overall block I\/O weight for the executed processes, if the unified control group hierarchy is used on the system. Takes a space\u2212separated pair of a file path and a weight value to specify the device specific weight value, between 1 and 10000. (Example: &#8220;\/dev\/sda 1000&#8221;). The file path may be specified as path to a block device node or as any other file, in which case the backing block device of the file system of the file is determined. This controls the &#8220;io.weight&#8221; control group attribute, which defaults to 100. Use this option multiple times to set weights for multiple devices. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">IO Interface Files<\/font><\/b> <small><font color=\"#000000\">[8]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting replaces <i>BlockIODeviceWeight=<\/i> and disables settings prefixed with <i>BlockIO<\/i> or <i>StartupBlockIO<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The specified device node should reference a block device that has an I\/O scheduler associated, i.e. should not refer to partition or loopback block devices, but to the originating, physical device. When a path to a regular file or directory is specified it is attempted to discover the correct originating device backing the file system of the specified path. This works correctly only for simpler cases, where the file system is directly placed on a partition or physical block device, or where simple 1:1 encryption using dm\u2212crypt\/LUKS is used. This discovery does not cover complex storage and in particular RAID and volume management storage devices.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IOReadBandwidthMax=device bytes<\/i>, <i>IOWriteBandwidthMax=device bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the per\u2212device overall block I\/O bandwidth maximum limit for the executed processes, if the unified control group hierarchy is used on the system. This limit is not work\u2212conserving and the executed processes are not allowed to use more even if the device has idle capacity. Takes a space\u2212separated pair of a file path and a bandwidth value (in bytes per second) to specify the device specific bandwidth. The file path may be a path to a block device node, or as any other file in which case the backing block device of the file system of the file is used. If the bandwidth is suffixed with K, M, G, or T, the specified bandwidth is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes, respectively, to the base of 1000. (Example: &#8220;\/dev\/disk\/by\u2212path\/pci\u22120000:00:1f.2\u2212scsi\u22120:0:0:0 5M&#8221;). This controls the &#8220;io.max&#8221; control group attributes. Use this option multiple times to set bandwidth limits for multiple devices. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">IO Interface Files<\/font><\/b> <small><font color=\"#000000\">[8]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings replace <i>BlockIOReadBandwidth=<\/i> and <i>BlockIOWriteBandwidth=<\/i> and disable settings prefixed with <i>BlockIO<\/i> or <i>StartupBlockIO<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Similar restrictions on block device discovery as for <i>IODeviceWeight=<\/i> apply, see above.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IOReadIOPSMax=device IOPS<\/i>, <i>IOWriteIOPSMax=device IOPS<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the per\u2212device overall block I\/O IOs\u2212Per\u2212Second maximum limit for the executed processes, if the unified control group hierarchy is used on the system. This limit is not work\u2212conserving and the executed processes are not allowed to use more even if the device has idle capacity. Takes a space\u2212separated pair of a file path and an IOPS value to specify the device specific IOPS. The file path may be a path to a block device node, or as any other file in which case the backing block device of the file system of the file is used. If the IOPS is suffixed with K, M, G, or T, the specified IOPS is parsed as KiloIOPS, MegaIOPS, GigaIOPS, or TeraIOPS, respectively, to the base of 1000. (Example: &#8220;\/dev\/disk\/by\u2212path\/pci\u22120000:00:1f.2\u2212scsi\u22120:0:0:0 1K&#8221;). This controls the &#8220;io.max&#8221; control group attributes. Use this option multiple times to set IOPS limits for multiple devices. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">IO Interface Files<\/font><\/b> <small><font color=\"#000000\">[8]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings are supported only if the unified control group hierarchy is used and disable settings prefixed with <i>BlockIO<\/i> or <i>StartupBlockIO<\/i>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Similar restrictions on block device discovery as for <i>IODeviceWeight=<\/i> apply, see above.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IODeviceLatencyTargetSec=device target<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the per\u2212device average target I\/O latency for the executed processes, if the unified control group hierarchy is used on the system. Takes a file path and a timespan separated by a space to specify the device specific latency target. (Example: &#8220;\/dev\/sda 25ms&#8221;). The file path may be specified as path to a block device node or as any other file, in which case the backing block device of the file system of the file is determined. This controls the &#8220;io.latency&#8221; control group attribute. Use this option multiple times to set latency target for multiple devices. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">IO Interface Files<\/font><\/b> <small><font color=\"#000000\">[8]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Implies &#8220;IOAccounting=yes&#8221;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings are supported only if the unified control group hierarchy is used.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Similar restrictions on block device discovery as for <i>IODeviceWeight=<\/i> apply, see above.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IPAccounting=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Takes a boolean argument. If true, turns on IPv4 and IPv6 network traffic accounting for packets sent or received by the unit. When this option is turned on, all IPv4 and IPv6 sockets created by any process of the unit are accounted for.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">When this option is used in socket units, it applies to all IPv4 and IPv6 sockets associated with it (including both listening and connection sockets where this applies). Note that for socket\u2212activated services, this configuration setting and the accounting data of the service unit and the socket unit are kept separate, and displayed separately. No propagation of the setting and the collected statistics is done, in either direction. Moreover, any traffic sent or received on any of the socket unit&#8217;s sockets is accounted to the socket unit \u2014 and never to the service unit it might have activated, even if the socket is used by it.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The system default for this setting may be controlled with <i>DefaultIPAccounting=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IPAddressAllow=ADDRESS[\/PREFIXLENGTH]&#8230;<\/i>, <i>IPAddressDeny=ADDRESS[\/PREFIXLENGTH]&#8230;<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turn on network traffic filtering for IP packets sent and received over <b>AF_INET<\/b> and <b>AF_INET6<\/b> sockets. Both directives take a space separated list of IPv4 or IPv6 addresses, each optionally suffixed with an address prefix length in bits after a &#8220;\/&#8221; character. If the suffix is omitted, the address is considered a host address, i.e. the filter covers the whole address (32 bits for IPv4, 128 bits for IPv6).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The access lists configured with this option are applied to all sockets created by processes of this unit (or in the case of socket units, associated with it). The lists are implicitly combined with any lists configured for any of the parent slice units this unit might be a member of. By default both access lists are empty. Both ingress and egress traffic is filtered by these settings. In case of ingress traffic the source IP address is checked against these access lists, in case of egress traffic the destination IP address is checked. The following rules are applied in turn:<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">\u2022 Access is granted when the checked IP address matches an entry in the <i>IPAddressAllow=<\/i> list.<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">\u2022 Otherwise, access is denied when the checked IP address matches an entry in the <i>IPAddressDeny=<\/i> list.<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">\u2022 Otherwise, access is granted.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">In order to implement an allow\u2212listing IP firewall, it is recommended to use a <i>IPAddressDeny=<\/i><b>any<\/b> setting on an upper\u2212level slice unit (such as the root slice \u2212.slice or the slice containing all system services system.slice \u2013 see <b>systemd.special<\/b>(7) for details on these slice units), plus individual per\u2212service <i>IPAddressAllow=<\/i> lines permitting network access to relevant services, and only them.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Note that for socket\u2212activated services, the IP access list configured on the socket unit applies to all sockets associated with it directly, but not to any sockets created by the ultimately activated services for it. Conversely, the IP access list configured for the service is not applied to any sockets passed into the service via socket activation. Thus, it is usually a good idea to replicate the IP access lists on both the socket and the service unit. Nevertheless, it may make sense to maintain one list more open and the other one more restricted, depending on the usecase.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">If these settings are used multiple times in the same unit the specified lists are combined. If an empty string is assigned to these settings the specific access list is reset and all previous settings undone.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">In place of explicit IPv4 or IPv6 address and prefix length specifications a small set of symbolic names may be used. The following names are defined:<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>Table\u00a01.\u00a0Special address\/network names<\/b><\/font><\/p>\n<p align=\"center\"><font color=\"#000000\"><b><img decoding=\"async\" src=\"grohtml-1260141.png\" alt=\"Image grohtml-1260141.png\"><\/b><\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Note that these settings might not be supported on some systems (for example if eBPF control group support is not enabled in the underlying kernel or container manager). These settings will have no effect in that case. If compatibility with such systems is desired it is hence recommended to not exclusively rely on them for IP security.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>IPIngressFilterPath=BPF_FS_PROGRAM_PATH<\/i>, <i>IPEgressFilterPath=BPF_FS_PROGRAM_PATH<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Add custom network traffic filters implemented as BPF programs, applying to all IP packets sent and received over <b>AF_INET<\/b> and <b>AF_INET6<\/b> sockets. Takes an absolute path to a pinned BPF program in the BPF virtual filesystem (\/sys\/fs\/bpf\/).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The filters configured with this option are applied to all sockets created by processes of this unit (or in the case of socket units, associated with it). The filters are loaded in addition to filters any of the parent slice units this unit might be a member of as well as any <i>IPAddressAllow=<\/i> and <i>IPAddressDeny=<\/i> filters in any of these units. By default there are no filters specified.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">If these settings are used multiple times in the same unit all the specified programs are attached. If an empty string is assigned to these settings the program list is reset and all previous specified programs ignored.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Note that for socket\u2212activated services, the IP filter programs configured on the socket unit apply to all sockets associated with it directly, but not to any sockets created by the ultimately activated services for it. Conversely, the IP filter programs configured for the service are not applied to any sockets passed into the service via socket activation. Thus, it is usually a good idea, to replicate the IP filter programs on both the socket and the service unit, however it often makes sense to maintain one configuration more open and the other one more restricted, depending on the usecase.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Note that these settings might not be supported on some systems (for example if eBPF control group support is not enabled in the underlying kernel or container manager). These settings will fail the service in that case. If compatibility with such systems is desired it is hence recommended to attach your filter manually (requires <i>Delegate=<\/i><b>yes<\/b>) instead of using this setting.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>DeviceAllow=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Control access to specific device nodes by the executed processes. Takes two space\u2212separated strings: a device node specifier followed by a combination of <b>r<\/b>, <b>w<\/b>, <b>m<\/b> to control <i>r<\/i>eading, <i>w<\/i>riting, or creation of the specific device node(s) by the unit (<i>m<\/i>knod), respectively. On cgroup\u2212v1 this controls the &#8220;devices.allow&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Device Whitelist Controller<\/font><\/b> <small><font color=\"#000000\">[9]<\/font><\/small> <font color=\"#000000\">. In the unified cgroup hierarchy this functionality is implemented using eBPF filtering.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The device node specifier is either a path to a device node in the file system, starting with \/dev\/, or a string starting with either &#8220;char\u2212&#8221; or &#8220;block\u2212&#8221; followed by a device group name, as listed in \/proc\/devices. The latter is useful to allow\u2212list all current and future devices belonging to a specific device group at once. The device group is matched according to filename globbing rules, you may hence use the &#8220;*&#8221; and &#8220;?&#8221; wildcards. (Note that such globbing wildcards are not available for device node path specifications!) In order to match device nodes by numeric major\/minor, use device node paths in the \/dev\/char\/ and \/dev\/block\/ directories. However, matching devices by major\/minor is generally not recommended as assignments are neither stable nor portable between systems or different kernel versions.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Examples: \/dev\/sda5 is a path to a device node, referring to an ATA or SCSI block device. &#8220;char\u2212pts&#8221; and &#8220;char\u2212alsa&#8221; are specifiers for all pseudo TTYs and all ALSA sound devices, respectively. &#8220;char\u2212cpu\/*&#8221; is a specifier matching all CPU related device groups.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Note that allow lists defined this way should only reference device groups which are resolvable at the time the unit is started. Any device groups not resolvable then are not added to the device allow list. In order to work around this limitation, consider extending service units with a pair of <b>After=modprobe@xyz.service<\/b> and <b>Wants=modprobe@xyz.service<\/b> lines that load the necessary kernel module implementing the device group if missing. Example:<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">&#8230; <br \/> [Unit] <br \/> Wants=modprobe@loop.service <br \/> After=modprobe@loop.service<\/font><\/p>\n<p style=\"margin-left:23%; margin-top: 1em\"><font color=\"#000000\">[Service] <br \/> DeviceAllow=block\u2212loop <br \/> DeviceAllow=\/dev\/loop\u2212control <br \/> &#8230;<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>DevicePolicy=auto|closed|strict<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Control the policy for allowing device access:<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>strict<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">means to only allow types of access that are explicitly specified.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>closed<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">in addition, allows access to standard pseudo devices including \/dev\/null, \/dev\/zero, \/dev\/full, \/dev\/random, and \/dev\/urandom.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\"><b>auto<\/b><\/font><\/p>\n<p style=\"margin-left:23%;\"><font color=\"#000000\">in addition, allows access to all devices if no explicit <i>DeviceAllow=<\/i> is present. This is the default.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>Slice=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">The name of the slice unit to place the unit in. Defaults to system.slice for all non\u2212instantiated units of all unit types (except for slice units themselves see below). Instance units are by default placed in a subslice of system.slice that is named after the template name.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This option may be used to arrange systemd units in a hierarchy of slices each of which might have resource settings applied.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">For units of type slice, the only accepted value for this setting is the parent slice. Since the name of a slice unit implies the parent slice, it is hence redundant to ever set this parameter directly for slice units.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Special care should be taken when relying on the default slice assignment in templated service units that have <i>DefaultDependencies=no<\/i> set, see <b>systemd.service<\/b>(5), section &#8220;Default Dependencies&#8221; for details.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>Delegate=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turns on delegation of further resource control partitioning to processes of the unit. Units where this is enabled may create and manage their own private subhierarchy of control groups below the control group of the unit itself. For unprivileged services (i.e. those using the <i>User=<\/i> setting) the unit&#8217;s control group will be made accessible to the relevant user. When enabled the service manager will refrain from manipulating control groups or moving processes below the unit&#8217;s control group, so that a clear concept of ownership is established: the control group tree above the unit&#8217;s control group (i.e. towards the root control group) is owned and managed by the service manager of the host, while the control group tree below the unit&#8217;s control group is owned and managed by the unit itself. Takes either a boolean argument or a list of control group controller names. If true, delegation is turned on, and all supported controllers are enabled for the unit, making them available to the unit&#8217;s processes for management. If false, delegation is turned off entirely (and no additional controllers are enabled). If set to a list of controllers, delegation is turned on, and the specified controllers are enabled for the unit. Note that additional controllers than the ones specified might be made available as well, depending on configuration of the containing slice unit or other units contained in it. Note that assigning the empty string will enable delegation, but reset the list of controllers, all assignments prior to this will have no effect. Defaults to false.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Note that controller delegation to less privileged code is only safe on the unified control group hierarchy. Accordingly, access to the specified controllers will not be granted to unprivileged services on the legacy hierarchy, even when requested.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The following controller names may be specified: <b>cpu<\/b>, <b>cpuacct<\/b>, <b>cpuset<\/b>, <b>io<\/b>, <b>blkio<\/b>, <b>memory<\/b>, <b>devices<\/b>, <b>pids<\/b>, <b>bpf\u2212firewall<\/b>, and <b>bpf\u2212devices<\/b>.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Not all of these controllers are available on all kernels however, and some are specific to the unified hierarchy while others are specific to the legacy hierarchy. Also note that the kernel might support further controllers, which aren&#8217;t covered here yet as delegation is either not supported at all for them or not defined cleanly.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">For further details on the delegation model consult<\/font> <b><font color=\"#0000FF\">Control Group APIs and Delegation<\/font><\/b> <small><font color=\"#000000\">[10]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>DisableControllers=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Disables controllers from being enabled for a unit&#8217;s children. If a controller listed is already in use in its subtree, the controller will be removed from the subtree. This can be used to avoid child units being able to implicitly or explicitly enable a controller. Defaults to not disabling any controllers.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">It may not be possible to successfully disable a controller if the unit or any child of the unit in question delegates controllers to its children, as any delegated subtree of the cgroup hierarchy is unmanaged by systemd.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Multiple controllers may be specified, separated by spaces. You may also pass <i>DisableControllers=<\/i> multiple times, in which case each new instance adds another controller to disable. Passing <i>DisableControllers=<\/i> by itself with no controller name present resets the disabled controller list.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">The following controller names may be specified: <b>cpu<\/b>, <b>cpuacct<\/b>, <b>cpuset<\/b>, <b>io<\/b>, <b>blkio<\/b>, <b>memory<\/b>, <b>devices<\/b>, <b>pids<\/b>, <b>bpf\u2212firewall<\/b>, and <b>bpf\u2212devices<\/b>.<\/font><\/p>\n<h2>DEPRECATED OPTIONS <a name=\"DEPRECATED OPTIONS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\">The following options are deprecated. Use the indicated superseding options instead:<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>CPUShares=weight<\/i>, <i>StartupCPUShares=weight<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Assign the specified CPU time share weight to the processes executed. These options take an integer value and control the &#8220;cpu.shares&#8221; control group attribute. The allowed range is 2 to 262144. Defaults to 1024. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">CFS Scheduler<\/font><\/b> <small><font color=\"#000000\">[4]<\/font><\/small> <font color=\"#000000\">. The available CPU time is split up among all units within one slice relative to their CPU time share weight.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">While <i>StartupCPUShares=<\/i> only applies to the startup phase of the system, <i>CPUShares=<\/i> applies to normal runtime of the system, and if the former is not set also to the startup phase. Using <i>StartupCPUShares=<\/i> allows prioritizing specific services at boot\u2212up differently than during normal runtime.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Implies &#8220;CPUAccounting=yes&#8221;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings are deprecated. Use <i>CPUWeight=<\/i> and <i>StartupCPUWeight=<\/i> instead.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>MemoryLimit=bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Specify the limit on maximum memory usage of the executed processes. The limit specifies how much process and kernel memory can be used by tasks in this unit. Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the system. If assigned the special value &#8220;infinity&#8221;, no memory limit is applied. This controls the &#8220;memory.limit_in_bytes&#8221; control group attribute. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Memory Resource Controller<\/font><\/b> <small><font color=\"#000000\">[11]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Implies &#8220;MemoryAccounting=yes&#8221;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is deprecated. Use <i>MemoryMax=<\/i> instead.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>BlockIOAccounting=<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Turn on Block I\/O accounting for this unit, if the legacy control group hierarchy is used on the system. Takes a boolean argument. Note that turning on block I\/O accounting for one unit will also implicitly turn it on for all units contained in the same slice and all for its parent slices and the units contained therein. The system default for this setting may be controlled with <i>DefaultBlockIOAccounting=<\/i> in <b>systemd-system.conf<\/b>(5).<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is deprecated. Use <i>IOAccounting=<\/i> instead.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>BlockIOWeight=weight<\/i>, <i>StartupBlockIOWeight=weight<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the default overall block I\/O weight for the executed processes, if the legacy control group hierarchy is used on the system. Takes a single weight value (between 10 and 1000) to set the default block I\/O weight. This controls the &#8220;blkio.weight&#8221; control group attribute, which defaults to 500. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Block IO Controller<\/font><\/b> <small><font color=\"#000000\">[12]<\/font><\/small> <font color=\"#000000\">. The available I\/O bandwidth is split up among all units within one slice relative to their block I\/O weight.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">While <i>StartupBlockIOWeight=<\/i> only applies to the startup phase of the system, <i>BlockIOWeight=<\/i> applies to the later runtime of the system, and if the former is not set also to the startup phase. This allows prioritizing specific services at boot\u2212up differently than during runtime.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Implies &#8220;BlockIOAccounting=yes&#8221;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings are deprecated. Use <i>IOWeight=<\/i> and <i>StartupIOWeight=<\/i> instead.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>BlockIODeviceWeight=device weight<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the per\u2212device overall block I\/O weight for the executed processes, if the legacy control group hierarchy is used on the system. Takes a space\u2212separated pair of a file path and a weight value to specify the device specific weight value, between 10 and 1000. (Example: &#8220;\/dev\/sda 500&#8221;). The file path may be specified as path to a block device node or as any other file, in which case the backing block device of the file system of the file is determined. This controls the &#8220;blkio.weight_device&#8221; control group attribute, which defaults to 1000. Use this option multiple times to set weights for multiple devices. For details about this control group attribute, see<\/font> <b><font color=\"#0000FF\">Block IO Controller<\/font><\/b> <small><font color=\"#000000\">[12]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Implies &#8220;BlockIOAccounting=yes&#8221;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">This setting is deprecated. Use <i>IODeviceWeight=<\/i> instead.<\/font><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><i>BlockIOReadBandwidth=device bytes<\/i>, <i>BlockIOWriteBandwidth=device bytes<\/i><\/font><\/p>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">Set the per\u2212device overall block I\/O bandwidth limit for the executed processes, if the legacy control group hierarchy is used on the system. Takes a space\u2212separated pair of a file path and a bandwidth value (in bytes per second) to specify the device specific bandwidth. The file path may be a path to a block device node, or as any other file in which case the backing block device of the file system of the file is used. If the bandwidth is suffixed with K, M, G, or T, the specified bandwidth is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes, respectively, to the base of 1000. (Example: &#8220;\/dev\/disk\/by\u2212path\/pci\u22120000:00:1f.2\u2212scsi\u22120:0:0:0 5M&#8221;). This controls the &#8220;blkio.throttle.read_bps_device&#8221; and &#8220;blkio.throttle.write_bps_device&#8221; control group attributes. Use this option multiple times to set bandwidth limits for multiple devices. For details about these control group attributes, see<\/font> <b><font color=\"#0000FF\">Block IO Controller<\/font><\/b> <small><font color=\"#000000\">[12]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">Implies &#8220;BlockIOAccounting=yes&#8221;.<\/font><\/p>\n<p style=\"margin-left:17%; margin-top: 1em\"><font color=\"#000000\">These settings are deprecated. Use <i>IOReadBandwidthMax=<\/i> and <i>IOWriteBandwidthMax=<\/i> instead.<\/font><\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><font color=\"#000000\"><b>systemd<\/b>(1), <b>systemd-system.conf<\/b>(5), <b>systemd.unit<\/b>(5), <b>systemd.service<\/b>(5), <b>systemd.slice<\/b>(5), <b>systemd.scope<\/b>(5), <b>systemd.socket<\/b>(5), <b>systemd.mount<\/b>(5), <b>systemd.swap<\/b>(5), <b>systemd.exec<\/b>(5), <b>systemd.directives<\/b>(7), <b>systemd.special<\/b>(7), The documentation for control groups and specific controllers in the Linux kernel:<\/font> <b><font color=\"#0000FF\">Control Groups v2<\/font><\/b> <small><font color=\"#000000\">[2]<\/font><\/small> <font color=\"#000000\">.<\/font><\/p>\n<h2>NOTES <a name=\"NOTES\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">1.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"43%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">New Control Group Interfaces<\/font><\/p>\n<\/td>\n<td width=\"40%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.freedesktop.org\/wiki\/Software\/systemd\/ControlGroupInterface\/<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">2.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"26%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Control Groups v2<\/font><\/p>\n<\/td>\n<td width=\"57%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v2.html<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">3.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"37%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Control Groups version 1<\/font><\/p>\n<\/td>\n<td width=\"46%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v1\/<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">4.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"20%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">CFS Scheduler<\/font><\/p>\n<\/td>\n<td width=\"63%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/scheduler\/sched-design-CFS.html<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">5.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"20%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">sched-bwc.txt<\/font><\/p>\n<\/td>\n<td width=\"63%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/Documentation\/scheduler\/sched-bwc.txt<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">6.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"34%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Memory Interface Files<\/font><\/p>\n<\/td>\n<td width=\"49%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v2.html#memory-interface-files<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">7.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"38%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Process Number Controller<\/font><\/p>\n<\/td>\n<td width=\"45%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v1\/pids.html<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">8.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"28%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">IO Interface Files<\/font><\/p>\n<\/td>\n<td width=\"55%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v2.html#io-interface-files<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"12%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">9.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"41%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Device Whitelist Controller<\/font><\/p>\n<\/td>\n<td width=\"42%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v1\/devices.html<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">10.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"51%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Control Group APIs and Delegation<\/font><\/p>\n<\/td>\n<td width=\"32%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/systemd.io\/CGROUP_DELEGATION<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">11.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"40%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Memory Resource Controller<\/font><\/p>\n<\/td>\n<td width=\"43%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v1\/memory.html<\/font><\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"4%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">12.<\/font><\/p>\n<\/td>\n<td width=\"2%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><font color=\"#000000\">Block IO Controller<\/font><\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%;\"><font color=\"#000000\">https:\/\/www.kernel.org\/doc\/html\/latest\/admin-guide\/cgroup-v1\/blkio-controller.html<\/font><\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  systemd.resource-control \u2212 Resource control unit settings <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[959],"tags":[961,1291,978],"class_list":["post-4477","post","type-post","status-publish","format-standard","hentry","category-5-formatos-de-ficheros","tag-961","tag-man5","tag-systemd"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/4477","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=4477"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/4477\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=4477"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=4477"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=4477"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}