Page 1 of 3

check_disk v2.0.3 -x failed on centos 7 with docker mounts

Posted: Thu Oct 13, 2016 12:13 pm
by nagmoto
Errors

Code: Select all

[root@ops01 ~]# /usr/lib64/nagios/plugins/check_disk -l -w 5% -c 3% -X tmpfs -X devtmpfs -X /dev/dm-14 -X /dev/dm-13 -X tmpfs  -x / -x /boot
DISK CRITICAL - net:[4026532622] is not accessible: No such file or directory
[root@ops01 ~]#
Mount info

Code: Select all

[root@ops01 ~]# cat /etc/redhat-release
CentOS Linux release 7.2.1511 (Core)
[root@ops01 ~]# /usr/lib64/nagios/plugins/check_disk --version
check_disk v2.0.3 (nagios-plugins 2.0.3)
[root@ops01 ~]# df
Filesystem                          1K-blocks     Used Available Use% Mounted on
/dev/mapper/centos-root              37300436 11798860  25501576  32% /
devtmpfs                              8117092        0   8117092   0% /dev
tmpfs                                 8132460       12   8132448   1% /dev/shm
tmpfs                                 8132460    25832   8106628   1% /run
tmpfs                                 8132460        0   8132460   0% /sys/fs/cgroup
<snipped>
/dev/dm-14                           10474496   403564  10070932   4% /var/lib/docker/devicemapper/mnt/73f6db02095526dbe8a3fd8db384dff5a2696051f9763a72ad6e53ff0ee6ebcf
shm                                     65536        0     65536   0% /var/lib/docker/containers/76527ed23b11542ea4c31e3360f5db5bcd1b46c5739193323822318dabce400b/shm
/dev/dm-13                           10474496   557876   9916620   6% /var/lib/docker/devicemapper/mnt/abd59bc3dbcd725cfc2881aa4ddeb7db3f2601a552c8a65f30037323920aa653
shm                                     65536        0     65536   0% /var/lib/docker/containers/28579998e994403e0282adf1c50fbe0ed64dde1cd106df0c7d1ecf0645c9d33e/shm
tmpfs                                 1626492        0   1626492   0% /run/user/0
[root@ops01 ~]#

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Thu Oct 13, 2016 1:54 pm
by avandemore
What is the output from /usr/lib64/nagios/plugins/check_disk -l -w 5% -c 3% -X tmpfs -X devtmpfs -X /dev/dm-14 -X /dev/dm-13 -x / -x /boot -v 3

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Thu Oct 13, 2016 1:55 pm
by ssax
Also, please post the output of the mount command:

Code: Select all

mount

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Thu Oct 13, 2016 2:37 pm
by nagmoto
Answer to Q1:

Code: Select all

[root@ops01 ~]# /usr/lib64/nagios/plugins/check_disk -l -w 5% -c 3% -X tmpfs -X devtmpfs -X /dev/dm-14 -X /dev/dm-13 -x / -x /boot -v 3
DISK CRITICAL - net:[4026532622] is not accessible: No such file or directory
[root@ops01 ~]#
Answer to Q2:

Code: Select all

[root@ops01 ~]# mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
devtmpfs on /dev type devtmpfs (rw,nosuid,size=8117092k,nr_inodes=2029273,mode=755)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,nodev,mode=755)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct,cpu)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/mapper/centos-root on / type xfs (rw,relatime,attr2,inode64,noquota)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=32,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw,relatime)
nfsd on /proc/fs/nfsd type nfsd (rw,relatime)
<snipped>
/dev/sda1 on /boot type xfs (rw,relatime,attr2,inode64,noquota)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
/dev/mapper/centos-root on /var/lib/docker/devicemapper type xfs (rw,relatime,attr2,inode64,noquota)
tmpfs on /run/user/35542 type tmpfs (rw,nosuid,nodev,relatime,size=1626492k,mode=700,uid=35542,gid=20225)
<snipped>
(rw,relatime,vers=3,rsize=524288,wsize=524288,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=100.65.177.222,mountvers=3,mountport=20048,mountproto=udp,local_lock=none,addr=100.65.177.222)
/dev/mapper/docker-253:0-202986118-73f6db02095526dbe8a3fd8db384dff5a2696051f9763a72ad6e53ff0ee6ebcf on /var/lib/docker/devicemapper/mnt/73f6db02095526dbe8a3fd8db384dff5a2696051f9763a72ad6e53ff0ee6ebcf type xfs (rw,relatime,nouuid,attr2,inode64,logbsize=64k,sunit=128,swidth=128,noquota)
shm on /var/lib/docker/containers/76527ed23b11542ea4c31e3360f5db5bcd1b46c5739193323822318dabce400b/shm type tmpfs (rw,nosuid,nodev,noexec,relatime,size=65536k)
proc on /run/docker/netns/1e51a501936d type proc (rw,nosuid,nodev,noexec,relatime)
/dev/mapper/docker-253:0-202986118-abd59bc3dbcd725cfc2881aa4ddeb7db3f2601a552c8a65f30037323920aa653 on /var/lib/docker/devicemapper/mnt/abd59bc3dbcd725cfc2881aa4ddeb7db3f2601a552c8a65f30037323920aa653 type xfs (rw,relatime,nouuid,attr2,inode64,logbsize=64k,sunit=128,swidth=128,noquota)
shm on /var/lib/docker/containers/28579998e994403e0282adf1c50fbe0ed64dde1cd106df0c7d1ecf0645c9d33e/shm type tmpfs (rw,nosuid,nodev,noexec,relatime,size=65536k)
proc on /run/docker/netns/10d9d4c80bcf type proc (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/user/0 type tmpfs (rw,nosuid,nodev,relatime,size=1626492k,mode=700)
[root@ops01 ~]#


Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Thu Oct 13, 2016 2:48 pm
by avandemore
What is the output from /usr/lib64/nagios/plugins/check_disk -l -w 5% -c 3% -X tmpfs -X devtmpfs -X /dev/dm-14 -X /dev/dm-13 -x / -x /boot -x /sys/fs/cgroup/net_cls?

You may just wish to use -X cgroup.

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Fri Oct 14, 2016 6:09 am
by nagmoto
Here is the output of requested command output.
[root@ops01 ~]# /usr/lib64/nagios/plugins/check_disk -l -w 5% -c 3% -X tmpfs -X devtmpfs -X /dev/dm-14 -X /dev/dm-13 -x / -x /boot -x /sys/fs/cgroup/net_cls
DISK CRITICAL - net:[4026532540] is not accessible: No such file or directory
[root@ops01 ~]# /usr/lib64/nagios/plugins/check_disk -l -w 5% -c 3% -X tmpfs -X devtmpfs -X /dev/dm-14 -X /dev/dm-13 -x / -x /boot -x /sys/fs/cgroup/net_cls -X cgroup
DISK CRITICAL - net:[4026532540] is not accessible: No such file or directory
[root@ops01 ~]#

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Fri Oct 14, 2016 1:11 pm
by dwhitfield
Has this ever worked? If so, were there any changes since it last worked?

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Sat Oct 15, 2016 1:44 am
by nagmoto
>Has this ever worked? If so, were there any changes since it last worked?
No, it never worked on CentOS 7 with docket enabled.
"-x" works on cenot7 without docker file system.

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Mon Oct 17, 2016 11:17 am
by dwhitfield
could you update your plugins? Here's a link to the latest version: https://nagios-plugins.org/download/nag ... 1.3.tar.gz

Also, on what version of Core are you running? If we find a bug, I just want to make sure it is in the most recent version so we can get in a bug report (and hopefully a fix) before the next release.

Re: check_disk v2.0.3 -x failed on centos 7 with docker moun

Posted: Mon Oct 17, 2016 11:28 am
by avandemore
I am unable to replicate this on a CentOS 7 install w/ docker:

Code: Select all

# /usr/local/nagios/libexec/check_disk  -l -w 5% -c 3% -X tmpfs -X devtmpfs -x / -x /boot
DISK OK - free space: /home 19253 MB (99% inode=99%); /var/lib/docker/devicemapper 37200 MB (94% inode=99%);| /home=32MB;18321;18707;0;19286 /var/lib/docker/devicemapper=2307MB;37532;38322;0;39508
What is the output of /usr/lib64/nagios/plugins/check_disk --version?