Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
root@CSDeb:/home/jobee# fdisk -l
Disk /dev/sda: 21.5 GB, 21474836480 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 2048 40136703 20067328 83 Linux
/dev/sda2 40138750 41940991 901121 5 Extended
/dev/sda5 40138752 41940991 901120 82 Linux swap / Solaris
/dev/sda2 on that debian system is an extended partition that has your /dev/sda5 swap partition (note the start block of /dev/sda5 is within the /dev/sda2 extended range and they end on the same block).
check_disk is for checking space in a mounted file system (which on that system, it is not a mounted file system)
I suspect /dev/sda2 on your centos system is not an extended partition and likely the location of your root mount point).
What you are seeing when you run check_disk on /dev/sda2 is the usage of your udev mount at /dev (look at your df output earlier and you'll see the 10mb number you're getting)
If you compare your 'fdisk -l /dev/sda' output from both servers, I expect you'll see the difference between the two systems.
Great points Millisa! If an exact match cannot be found, check_disk will attempt to find the next closest name. Since /dev/sda2 is not truly mounted, millisa is correct you likely will not be able to check a partition for that. You could force exact name matching with -E. It might force it to check lower down the list of partitions.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.