using NCPA to check used disk space
Posted: Wed Aug 24, 2016 7:21 am
Not sure if I'm running into another ncpa bug but df is displaying a different percentage than ncpa is coming back with.
Code: Select all
/usr/local/nagios/libexec/check_ncpa.py -H myhost -t 'valspar' -P 5693 -M 'disk/logical/|mymount' -w 90 -c 95 -v
Connecting to: https://myhost:5693/api/disk/logical/|mymount/?token=mytoken&warning=90&critical=95&check=1
File returned contained:
{
"value": {
"returncode": 0,
"stdout": "OK: used_percent was 85% -- total_size was 3246541676544b -- used was 2783541846016b -- free was 298108321792b | 'used_percent_0'=85%;90;95;"
}
}
OK: used_percent was 85% -- total_size was 3246541676544b -- used was 2783541846016b -- free was 298108321792b | 'used_percent_0'=85%;90;95;
myhost:root /usr/local/ncpa/var # df -k | grep mymount
/dev/mapper/vg_mymount-lv_mymount
3170450856 2718302584 291121408 91% /mymount