summaryrefslogtreecommitdiffstats
path: root/collectors/cgroups.plugin
diff options
context:
space:
mode:
authorVladimir Kobal <vlad@prokk.net>2018-12-30 17:37:09 +0200
committerGitHub <noreply@github.com>2018-12-30 17:37:09 +0200
commit9b96eee1601ee3ef1bcf8fd5d5ad2c572b026fc9 (patch)
treed2ba7cb45ed51f9c8664c06362915b4c51c852ed /collectors/cgroups.plugin
parent3122b23daabb233178c93805a5c55fd3e27d8b20 (diff)
Add systemd pattern list parameter to the documentation (#5077)
* Add systemd pattern list parameter to the documentation * Remove newline in code fragment
Diffstat (limited to 'collectors/cgroups.plugin')
-rw-r--r--collectors/cgroups.plugin/README.md13
1 files changed, 10 insertions, 3 deletions
diff --git a/collectors/cgroups.plugin/README.md b/collectors/cgroups.plugin/README.md
index 018a07cc20..d4f6d8ce03 100644
--- a/collectors/cgroups.plugin/README.md
+++ b/collectors/cgroups.plugin/README.md
@@ -32,7 +32,7 @@ Linux exposes resource usage reporting and provides dynamic configuration for cg
path to /sys/fs/cgroup/blkio = /sys/fs/cgroup/blkio
path to /sys/fs/cgroup/memory = /sys/fs/cgroup/memory
path to /sys/fs/cgroup/devices = /sys/fs/cgroup/devices
-```
+```
netdata rescans these directories for added or removed cgroups every `check for new cgroups every` seconds.
@@ -51,7 +51,7 @@ To provide a sane default for this setting, netdata uses the following pattern l
```
[plugin:cgroups]
- search for cgroups in subpaths matching = !*/init.scope !*-qemu !/init.scope !/system !/systemd !/user !/user.slice *
+ search for cgroups in subpaths matching = !*/init.scope !*-qemu !/init.scope !/system !/systemd !/user !/user.slice *
```
So, we disable checking for **child cgroups** in systemd internal cgroups ([systemd services are monitored by netdata](#monitoring-systemd-services)), user cgroups (normally used for desktop and remote user sessions), qemu virtual machines (child cgroups of virtual machines) and `init.scope`. All others are enabled.
@@ -70,7 +70,7 @@ To provide a sane default, netdata uses the following pattern list (it checks th
```
[plugin:cgroups]
- enable by default cgroups matching = !*/init.scope *.scope !*/vcpu* !*/emulator !*.mount !*.partition !*.service !*.slice !*.swap !*.user !/ !/docker !/libvirt !/lxc !/lxc/*/ns !/lxc/*/ns/* !/machine !/qemu !/system !/systemd !/user *
+ enable by default cgroups matching = !*/init.scope *.scope !*/vcpu* !*/emulator !*.mount !*.partition !*.service !*.slice !*.swap !*.user !/ !/docker !/libvirt !/lxc !/lxc/*/ns !/lxc/*/ns/* !/machine !/qemu !/system !/systemd !/user *
```
The above provides the default `yes` or `no` setting for the cgroup. However, there is an additional step. In many cases the cgroups found in the `/sys/fs/cgroup` hierarchy are just random numbers and in many cases these numbers are ephemeral: they change across reboots or sessions.
@@ -158,6 +158,13 @@ cgroup_enable=memory swapaccount=1
You can add the above, directly at the `linux` line in your `/boot/grub/grub.cfg` or appending them to the `GRUB_CMDLINE_LINUX` in `/etc/default/grub` (in which case you will have to run `update-grub` before rebooting). On DigitalOcean debian images you may have to set it at `/etc/default/grub.d/50-cloudimg-settings.cfg`.
+Which systemd services are monitored by netdata is determined by the following pattern list:
+
+```
+[plugin:cgroups]
+ cgroups to match as systemd services = !/system.slice/*/*.service /system.slice/*.service
+```
+
---
## Monitoring ephemeral containers