check_disk stopped working on btrfs filesystems after installing kernel 3.18 (#1316)
Francois Conil
notifications at github.com
Tue Dec 30 02:41:03 CET 2014
Hi,
After upgrading the kernel to 3.18, we're experiencing the following error:
on a 3.16 host, btrfs FS:
```
/usr/lib/nagios/plugins/check_disk -w 10% -c 5% -p /var/lib/docker/btrfs
DISK OK - free space: /var/lib/docker/btrfs 67117 MB (69% inode=-);|
/var/lib/docker/btrfs=29640MB;92152;97272;0;102392
```
on a 3.18 host, btrfs FS:
```
/usr/lib/nagios/plugins/check_disk -w 10% -c 5% -p /
DISK CRITICAL - free space: / 0 MB (0% inode=-);|
/=134139MB;15451534;16309953;0;17168372
```
3.16 strace:
```
strace /usr/lib/nagios/plugins/check_disk -w 10% -c 5% -p
/var/lib/docker/btrfs
execve("/usr/lib/nagios/plugins/check_disk",
["/usr/lib/nagios/plugins/check_di"..., "-w", "10%", "-c", "5%", "-p",
"/var/lib/docker/btrfs"], [/* 21 vars */]) = 0
brk(0) = 0x7f671cbd0000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c67e000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or
directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=25947, ...}) = 0
mmap(NULL, 25947, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f671c677000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libpthread.so.0", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0@\\\0\0\0\0\0\0"...,
832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=131107, ...}) = 0
mmap(NULL, 2208672, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f671c245000
mprotect(0x7f671c25c000, 2093056, PROT_NONE) = 0
mmap(0x7f671c45b000, 8192, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x16000) = 0x7f671c45b000
mmap(0x7f671c45d000, 13216, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f671c45d000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libdl.so.2", O_RDONLY) = 3
read(3,
"\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\340\r\0\0\0\0\0\0"..., 832)
= 832
fstat(3, {st_mode=S_IFREG|0644, st_size=14768, ...}) = 0
mmap(NULL, 2109696, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f671c041000
mprotect(0x7f671c043000, 2097152, PROT_NONE) = 0
mmap(0x7f671c243000, 8192, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f671c243000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY) = 3
read(3,
"\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\300\357\1\0\0\0\0\0"...,
832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1603600, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c676000
mmap(NULL, 3717176, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f671bcb5000
mprotect(0x7f671be37000, 2097152, PROT_NONE) = 0
mmap(0x7f671c037000, 20480, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x182000) = 0x7f671c037000
mmap(0x7f671c03c000, 18488, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f671c03c000
close(3) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c675000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c674000
arch_prctl(ARCH_SET_FS, 0x7f671c675700) = 0
mprotect(0x7f671c037000, 16384, PROT_READ) = 0
mprotect(0x7f671c243000, 4096, PROT_READ) = 0
mprotect(0x7f671c45b000, 4096, PROT_READ) = 0
mprotect(0x7f671c8a0000, 4096, PROT_READ) = 0
mprotect(0x7f671c680000, 4096, PROT_READ) = 0
munmap(0x7f671c677000, 25947) = 0
set_tid_address(0x7f671c6759d0) = 9513
set_robust_list(0x7f671c6759e0, 0x18) = 0
futex(0x7fff6676092c, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 1,
NULL, 7f671c675700) = -1 EAGAIN (Resource temporarily unavailable)
rt_sigaction(SIGRTMIN, {0x7f671c24aad0, [], SA_RESTORER|SA_SIGINFO,
0x7f671c2540a0}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {0x7f671c24ab60, [],
SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x7f671c2540a0}, NULL, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0
brk(0) = 0x7f671cbd0000
brk(0x7f671cbf1000) = 0x7f671cbf1000
open("/usr/lib/locale/locale-archive", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=1534592, ...}) = 0
mmap(NULL, 1534592, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f671c4fd000
close(3) = 0
open("/etc/mtab", O_RDONLY) = 3
futex(0x7f671c03df00, FUTEX_WAKE_PRIVATE, 2147483647) = 0
fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c67d000
read(3, "rootfs / rootfs rw,seclabel 0 0\n"..., 1024) = 1024
read(3, "/lib/nfs/rpc_pipefs rpc_pipefs r"..., 1024) = 1024
read(3, "to=tcp,port=0,timeo=600,retrans="..., 1024) = 1024
read(3, "ze=262144,wsize=262144,namlen=25"..., 1024) = 1024
read(3, "nfs4 rw,noatime,vers=4.0,rsize=2"..., 1024) = 1024
read(3, "ss3test/storage nfs4 rw,noatime,"..., 1024) = 1024
read(3, "-4/storage /var/docker-mounts/sr"..., 1024) = 1024
read(3, "_lock=none,addr=10.51.11.40 0 0\n"..., 1024) = 1024
read(3, "/var/lib/docker/btrfs btrfs rw,s"..., 1024) = 374
read(3, "", 1024) = 0
close(3) = 0
munmap(0x7f671c67d000, 4096) = 0
stat("/var/lib/docker/btrfs", {st_mode=S_IFDIR|0700, st_size=20, ...}) = 0
open("/etc/mtab", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c67d000
read(3, "rootfs / rootfs rw,seclabel 0 0\n"..., 1024) = 1024
read(3, "/lib/nfs/rpc_pipefs rpc_pipefs r"..., 1024) = 1024
read(3, "to=tcp,port=0,timeo=600,retrans="..., 1024) = 1024
read(3, "ze=262144,wsize=262144,namlen=25"..., 1024) = 1024
read(3, "nfs4 rw,noatime,vers=4.0,rsize=2"..., 1024) = 1024
read(3, "ss3test/storage nfs4 rw,noatime,"..., 1024) = 1024
read(3, "-4/storage /var/docker-mounts/sr"..., 1024) = 1024
read(3, "_lock=none,addr=10.51.11.40 0 0\n"..., 1024) = 1024
read(3, "/var/lib/docker/btrfs btrfs rw,s"..., 1024) = 374
read(3, "", 1024) = 0
close(3) = 0
munmap(0x7f671c67d000, 4096) = 0
stat("/var/lib/docker/btrfs", {st_mode=S_IFDIR|0700, st_size=20, ...}) = 0
statfs("/var/lib/docker/btrfs", {f_type=0x9123683e, f_bsize=4096,
f_blocks=26212352, f_bfree=18624432, f_bavail=17182160, f_files=0,
f_ffree=0, f_fsid={-1714817651, 1111202320}, f_namelen=255, f_frsize=4096})
= 0
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f671c67d000
write(1, "DISK OK - free space: /var/lib/d"..., 120DISK OK - free space:
/var/lib/docker/btrfs 67117 MB (69% inode=-);|
/var/lib/docker/btrfs=29640MB;92152;97272;0;102392
) = 120
exit_group(0) = ?
```
3.18 strace:
```
strace /usr/lib/nagios/plugins/check_disk -w 10% -c 5% -p /
execve("/usr/lib/nagios/plugins/check_disk",
["/usr/lib/nagios/plugins/check_di"..., "-w", "10%", "-c", "5%", "-p", "/"],
[/* 21 vars */]) = 0
brk(0) = 0x7f52deaa9000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf1f000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or
directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=27730, ...}) = 0
mmap(NULL, 27730, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f52ddf18000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libpthread.so.0", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0@\\\0\0\0\0\0\0"...,
832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=131107, ...}) = 0
mmap(NULL, 2208672, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f52ddae6000
mprotect(0x7f52ddafd000, 2093056, PROT_NONE) = 0
mmap(0x7f52ddcfc000, 8192, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x16000) = 0x7f52ddcfc000
mmap(0x7f52ddcfe000, 13216, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f52ddcfe000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libdl.so.2", O_RDONLY) = 3
read(3,
"\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\340\r\0\0\0\0\0\0"..., 832)
= 832
fstat(3, {st_mode=S_IFREG|0644, st_size=14768, ...}) = 0
mmap(NULL, 2109696, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f52dd8e2000
mprotect(0x7f52dd8e4000, 2097152, PROT_NONE) = 0
mmap(0x7f52ddae4000, 8192, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f52ddae4000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY) = 3
read(3,
"\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\300\357\1\0\0\0\0\0"...,
832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1603600, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf17000
mmap(NULL, 3717176, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f52dd556000
mprotect(0x7f52dd6d8000, 2097152, PROT_NONE) = 0
mmap(0x7f52dd8d8000, 20480, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x182000) = 0x7f52dd8d8000
mmap(0x7f52dd8dd000, 18488, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f52dd8dd000
close(3) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf16000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf15000
arch_prctl(ARCH_SET_FS, 0x7f52ddf16700) = 0
mprotect(0x7f52dd8d8000, 16384, PROT_READ) = 0
mprotect(0x7f52ddae4000, 4096, PROT_READ) = 0
mprotect(0x7f52ddcfc000, 4096, PROT_READ) = 0
mprotect(0x7f52de141000, 4096, PROT_READ) = 0
mprotect(0x7f52ddf21000, 4096, PROT_READ) = 0
munmap(0x7f52ddf18000, 27730) = 0
set_tid_address(0x7f52ddf169d0) = 26015
set_robust_list(0x7f52ddf169e0, 0x18) = 0
futex(0x7fff397aaeac, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 1,
NULL, 7f52ddf16700) = -1 EAGAIN (Resource temporarily unavailable)
rt_sigaction(SIGRTMIN, {0x7f52ddaebad0, [], SA_RESTORER|SA_SIGINFO,
0x7f52ddaf50a0}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {0x7f52ddaebb60, [],
SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x7f52ddaf50a0}, NULL, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0
brk(0) = 0x7f52deaa9000
brk(0x7f52deaca000) = 0x7f52deaca000
open("/usr/lib/locale/locale-archive", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=1534592, ...}) = 0
mmap(NULL, 1534592, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f52ddd9e000
close(3) = 0
open("/etc/mtab", O_RDONLY) = 3
futex(0x7f52dd8def00, FUTEX_WAKE_PRIVATE, 2147483647) = 0
fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf1e000
read(3, "rootfs / rootfs rw 0 0\nsysfs /sy"..., 1024) = 649
read(3, "", 1024) = 0
close(3) = 0
munmap(0x7f52ddf1e000, 4096) = 0
stat("/", {st_mode=S_IFDIR|0755, st_size=302, ...}) = 0
open("/etc/mtab", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf1e000
read(3, "rootfs / rootfs rw 0 0\nsysfs /sy"..., 1024) = 649
read(3, "", 1024) = 0
close(3) = 0
munmap(0x7f52ddf1e000, 4096) = 0
stat("/", {st_mode=S_IFDIR|0755, st_size=302, ...}) = 0
statfs("/", {f_type=0x9123683e, f_bsize=4096, f_blocks=4395103346,
f_bfree=4360763531, f_bavail=4361056400, f_files=0, f_ffree=0,
f_fsid={-1228765678, -1342971444}, f_namelen=255, f_frsize=4096}) = 0
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f52ddf1e000
write(1, "DISK CRITICAL - free space: / 0 "..., 90DISK CRITICAL - free
space: / 0 MB (0% inode=-);| /=134139MB;15451534;16309953;0;17168372
) = 90
exit_group(2) = ?
```
--
Reply to this email on GitHub:
https://github.com/monitoring-plugins/monitoring-plugins/issues/1316
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20141229/e7803768/attachment.html>
More information about the Devel
mailing list