-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
inputs.disks reading /proc/1/mountinfo instead of /proc/self/mountinfo #10388
Comments
Yes, that
Sorry, same problem, updated from
|
gopsutil implemented a fix for this issue by falling back to gopsutil has already been updated in #10931 |
Because #10931 has been merged into master, @hvisage can you please try with a nightly build to see if that fixes the issue? Nightly builds: https://github.com/influxdata/telegraf/blob/master/docs/NIGHTLIES.md |
Hello! I am closing this issue due to inactivity. I hope you were able to resolve your problem, if not please try posting this question in our Community Slack or Community Page. Thank you! |
Relevent telegraf.conf
Logs from Telegraf
telegraf@adebv2mx01:/root$ /usr/bin/telegraf -config /etc/telegraf/telegraf.conf -config-directory /etc/telegraf/telegraf.d --once --input-filter disk --debug
2022-01-05T23:36:44Z I! Starting Telegraf 1.21.1
2022-01-05T23:36:44Z I! Loaded inputs: disk
2022-01-05T23:36:44Z I! Loaded aggregators:
2022-01-05T23:36:44Z I! Loaded processors:
2022-01-05T23:36:44Z I! Loaded outputs: influxdb_v2
2022-01-05T23:36:44Z I! Tags enabled: client=AGW_AD client_env=EBV2 host=adebv2mx01 service_type=Mendix
2022-01-05T23:36:44Z D! [agent] Initializing plugins
2022-01-05T23:36:44Z D! [agent] Connecting outputs
2022-01-05T23:36:44Z D! [agent] Attempting connection to [outputs.influxdb_v2]
2022-01-05T23:36:44Z D! [agent] Successfully connected to outputs.influxdb_v2
2022-01-05T23:36:44Z D! [agent] Starting service inputs
2022-01-05T23:36:44Z E! [inputs.disk] Error in plugin: error getting disk usage info: open /proc/1/mounts: no such file or directory
2022-01-05T23:36:44Z D! [agent] Stopping service inputs
2022-01-05T23:36:44Z D! [agent] Input channel closed
2022-01-05T23:36:44Z I! [agent] Hang on, flushing any cached metrics before shutdown
2022-01-05T23:36:44Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
2022-01-05T23:36:44Z I! [agent] Stopping running outputs
2022-01-05T23:36:44Z D! [agent] Stopped Successfully
2022-01-05T23:36:44Z E! [telegraf] Error running agent: input plugins recorded 1 errors
System info
Debian 10.7 (Linux adebv2mx01 4.19.0-13-amd64 #1 SMP Debian 4.19.160-2 (2020-11-28) x86_64 GNU/Linux)
Docker
No response
Steps to reproduce
Expected behavior
Reading deta from /proc/self/mountinfo (or /proc/mounts) instead of /proc/1/mountingo or /
Actual behavior
reading from /proc/1/mountinfo
Additional info
root@adebv2mx01:
# strace -fff /usr/bin/telegraf -config /etc/telegraf/telegraf.conf -config-directory /etc/telegraf/telegraf.d --once --input-filter disk 2>&1 | grep -i proc/# sudo -u telegraf -s /bin/bash[pid 23995] readlinkat(AT_FDCWD, "/proc/self/exe", <unfinished ...>
[pid 23995] openat(AT_FDCWD, "/proc/stat", O_RDONLY|O_CLOEXEC) = 7
[pid 23995] openat(AT_FDCWD, "/proc/stat", O_RDONLY|O_CLOEXEC) = 7
[pid 23995] openat(AT_FDCWD, "/proc/23995/stat", O_RDONLY|O_CLOEXEC) = 7
[pid 23995] openat(AT_FDCWD, "/proc/1/mountinfo", O_RDONLY|O_CLOEXEC <unfinished ...>
[pid 23995] openat(AT_FDCWD, "/proc/filesystems", O_RDONLY|O_CLOEXEC) = 7
root@adebv2mx01:
telegraf@adebv2mx01:/root$ strace -fff /usr/bin/telegraf -config /etc/telegraf/telegraf.conf -config-directory /etc/telegraf/telegraf.d --once --input-filter disk 2>&1 | grep -i proc/
[pid 24040] readlinkat(AT_FDCWD, "/proc/self/exe", <unfinished ...>
[pid 24040] openat(AT_FDCWD, "/proc/stat", O_RDONLY|O_CLOEXEC <unfinished ...>
[pid 24040] openat(AT_FDCWD, "/proc/stat", O_RDONLY|O_CLOEXEC) = 7
[pid 24040] openat(AT_FDCWD, "/proc/24040/stat", O_RDONLY|O_CLOEXEC) = 7
[pid 24045] openat(AT_FDCWD, "/proc/1/mountinfo", O_RDONLY|O_CLOEXEC <unfinished ...>
[pid 24045] openat(AT_FDCWD, "/proc/1/mounts", O_RDONLY|O_CLOEXEC <unfinished ...>
[pid 24045] write(2, "2022-01-05T23:33:11Z E! [inputs."..., 1332022-01-05T23:33:11Z E! [inputs.disk] Error in plugin: error getting disk usage info: open /proc/1/mounts: no such file or directory
telegraf@adebv2mx01:/root$ telegraf --version
Telegraf 1.21.1 (git: HEAD 7c9a9c1)
telegraf@adebv2mx01:/root$ head /proc/self/mountinfo
19 24 0:18 / /sys rw,nosuid,nodev,noexec,relatime shared:7 - sysfs sysfs rw
20 24 0:4 / /proc rw,relatime shared:14 - proc proc rw,gid=70,hidepid=2
21 24 0:6 / /dev rw,nosuid,relatime shared:2 - devtmpfs udev rw,size=4068460k,nr_inodes=1017115,mode=755
22 21 0:19 / /dev/pts rw,nosuid,noexec,relatime shared:3 - devpts devpts rw,gid=5,mode=620,ptmxmode=000
23 24 0:20 / /run rw,nosuid,noexec,relatime shared:5 - tmpfs tmpfs rw,size=816988k,mode=755
24 0 8:1 / / rw,relatime shared:1 - ext4 /dev/sda1 rw,errors=remount-ro
25 19 0:7 / /sys/kernel/security rw,nosuid,nodev,noexec,relatime shared:8 - securityfs securityfs rw
26 21 0:21 / /dev/shm rw,nosuid,nodev shared:4 - tmpfs tmpfs rw
27 23 0:22 / /run/lock rw,nosuid,nodev,noexec,relatime shared:6 - tmpfs tmpfs rw,size=5120k
28 19 0:23 / /sys/fs/cgroup ro,nosuid,nodev,noexec shared:9 - tmpfs tmpfs ro,mode=755
telegraf@adebv2mx01:/root$ head /proc/filesystems
nodev sysfs
nodev rootfs
nodev ramfs
nodev bdev
nodev proc
nodev cpuset
nodev cgroup
nodev cgroup2
nodev tmpfs
nodev devtmpfs
The text was updated successfully, but these errors were encountered: