NCPA disk checks output

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

NCPA disk checks output

Post by dlukinski »

Hello Nagios support

Please help to understand why Nagios xI output is different from NCPA API output:

Say, ./check_ncpa.py -H fikc-alfind02.konecranes.com -t '<your token>' -M 'disk/logical/|solr|suggestions' -w 80 -c 90

1. This is what API promises to show: CRITICAL: Used disk space was 100.00 % (Used: 376.47 GiB, Free: 0.00 GiB, Total: 393.48 GiB) | 'used'=376.47GiB;315;354; 'free'=0.00GiB;315;354; 'total'=393.48GiB;315;354;


2. That is what XI shows: CRITICAL: Used_percent was 100 % (this is it)

- Where are Total /Free?
gsmith
Posts: 1253
Joined: Tue Mar 02, 2021 11:15 am

Re: NCPA disk checks output

Post by gsmith »

Hi

From the command line I get:

Code: Select all

[root@gs-cent8-23-82 greg]# /usr/local/nagios/libexec/check_ncpa.py -H 192.168.23.82 -t 'gjstoken' -P 5693 -M 'disk/logical/|greg' -w '70' -c '90'
CRITICAL: Used disk space was 100.00 % (Used: 0.46 GiB, Free: 0.00 GiB, Total: 0.46 GiB) | 'used'=0.46GiB;;; 'free'=0.00GiB;;; 'total'=0.46GiB;;;
[root@gs-cent8-23-82 greg]#
And here it is displayed ih the gui:
Image8.jpg
I even changed my mountpoint and got the same results:

Code: Select all

[root@gs-cent8-23-82 mysubdir]# mount -l
    ~ ~ ~ ~ ~
/dev/sdb on /greg/mysubdir type ext4 (rw,relatime)
Image9.jpg
So please provide the output of the following (using sudo if required):

Code: Select all

cat /etc/os-release
uname -a
mount -l
cat /usr/local/nagiosxi/var/xiversion|grep full
Also send me a System Profile:

To send us your system profile.
1. Login to the Nagios XI GUI using a web browser.
2. Click the "Admin" > "System Profile" Menu
3. Click the "Download Profile" button
4. Save the profile.zip file and share this in a private message and then reply to this post to bring it up in the queue.


Thanks
You do not have the required permissions to view the files attached to this post.
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Re: NCPA disk checks output

Post by dlukinski »

gsmith wrote:Hi

From the command line I get:

Code: Select all

[root@gs-cent8-23-82 greg]# /usr/local/nagios/libexec/check_ncpa.py -H 192.168.23.82 -t 'gjstoken' -P 5693 -M 'disk/logical/|greg' -w '70' -c '90'
CRITICAL: Used disk space was 100.00 % (Used: 0.46 GiB, Free: 0.00 GiB, Total: 0.46 GiB) | 'used'=0.46GiB;;; 'free'=0.00GiB;;; 'total'=0.46GiB;;;
[root@gs-cent8-23-82 greg]#
And here it is displayed ih the gui:
Image8.jpg
I even changed my mountpoint and got the same results:

Code: Select all

[root@gs-cent8-23-82 mysubdir]# mount -l
    ~ ~ ~ ~ ~
/dev/sdb on /greg/mysubdir type ext4 (rw,relatime)
Image9.jpg
So please provide the output of the following (using sudo if required):

Code: Select all

cat /etc/os-release
uname -a
mount -l
cat /usr/local/nagiosxi/var/xiversion|grep full
Also send me a System Profile:

To send us your system profile.
1. Login to the Nagios XI GUI using a web browser.
2. Click the "Admin" > "System Profile" Menu
3. Click the "Download Profile" button
4. Save the profile.zip file and share this in a private message and then reply to this post to bring it up in the queue.


Thanks
Hello

Profile is attached and the output is down below (please note that this is Nagios VMware template server)

Code: Select all

[root@fikc-nagxiprod01 ~]# cat /etc/os-release
NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:7"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"

CENTOS_MANTISBT_PROJECT="CentOS-7"
CENTOS_MANTISBT_PROJECT_VERSION="7"
REDHAT_SUPPORT_PRODUCT="centos"
REDHAT_SUPPORT_PRODUCT_VERSION="7"

[root@fikc-nagxiprod01 ~]# uname -a
Linux fikc-nagxiprod01 3.10.0-1160.36.2.el7.x86_64 #1 SMP Wed Jul 21 11:57:15 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
[root@fikc-nagxiprod01 ~]# mount -l
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=12245216k,nr_inodes=3061304,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/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_prio,net_cls)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct,cpu)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/mapper/centos-root on / type ext4 (rw,relatime,data=ordered)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=34,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=12714)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
mqueue on /dev/mqueue type mqueue (rw,relatime)
/dev/sda1 on /boot type ext4 (rw,relatime,data=ordered)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw,relatime)
tmpfs on /var/nagiosramdisk type tmpfs (rw,relatime,size=524288k)
fikc-isilon01.res.kcg.global:/ifs/data/fikc-nagxiprod01-backup on /mnt/nfs/backup type nfs (rw,relatime,vers=3,rsize=131072,wsize=524288,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=10.102.74.34,mountvers=3,mountport=300,mountproto=udp,local_lock=none,addr=10.102.74.34)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=2451384k,mode=700,uid=1000,gid=1000)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
tmpfs on /run/user/0 type tmpfs (rw,nosuid,nodev,relatime,size=2451384k,mode=700)
[root@fikc-nagxiprod01 ~]# cat /usr/local/nagiosxi/var/xiversion|grep full
full=5.8.5
[root@fikc-nagxiprod01 ~]#

gsmith
Posts: 1253
Joined: Tue Mar 02, 2021 11:15 am

Re: NCPA disk checks output

Post by gsmith »

Hi,

Thanks! I'll get this loaded after our afternoon staff meeting and will see if I get the same
results as you.

Thanks
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Re: NCPA disk checks output

Post by dlukinski »

gsmith wrote:Hi,

Thanks! I'll get this loaded after our afternoon staff meeting and will see if I get the same
results as you.

Thanks

Please update?
gsmith
Posts: 1253
Joined: Tue Mar 02, 2021 11:15 am

Re: NCPA disk checks output

Post by gsmith »

Hi,

My apologies. I was out sick all last week and will work on this today.

Thank you.
gsmith
Posts: 1253
Joined: Tue Mar 02, 2021 11:15 am

Re: NCPA disk checks output

Post by gsmith »

Hi

When I look at your service definition for "resource - PROD /solr/suggestions volume used 90w / 95c" I see:

Code: Select all

$USER1$/check_ncpa.py -H $HOSTADDRESS$ $ARG1$

-t 'alfresco' -P 5693 -M 'disk/logical/|solr|suggestions/used_percent' -w 90 -c 95 -u G

Please change it to:

Code: Select all

$USER1$/check_ncpa.py -H $HOSTADDRESS$ $ARG1$

-t 'alfresco' -P 5693 -M 'disk/logical/|solr|suggestions' -w 90 -c 95 -u G

Thanks
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Re: NCPA disk checks output

Post by dlukinski »

gsmith wrote:Hi

When I look at your service definition for "resource - PROD /solr/suggestions volume used 90w / 95c" I see:

Code: Select all

$USER1$/check_ncpa.py -H $HOSTADDRESS$ $ARG1$

-t 'alfresco' -P 5693 -M 'disk/logical/|solr|suggestions/used_percent' -w 90 -c 95 -u G

Please change it to:

Code: Select all

$USER1$/check_ncpa.py -H $HOSTADDRESS$ $ARG1$

-t 'alfresco' -P 5693 -M 'disk/logical/|solr|suggestions' -w 90 -c 95 -u G

Thanks
This worked, thank you!
- OK to close
Locked