Page 1 of 1

NCPA Wizard - Linux disk naming

Posted: Fri May 20, 2016 2:25 pm
by vAJ
I haven't used the NCPA wizard in a while, since all of my systems added lately use templates.

However, when running v1.3.5 of the wizard today, I noticed that it's pulling the device name for disk monitoring, instead of the logical name that it used to. Checking the changelog, I don't see where this was modified.

Frankly, I don't like it at all. I greatly prefer the logical naming for the labels on disk checks.

To do this, all I needed to do was edit line 212 in ncpa.inc.php:
from

Code: Select all

                $default_services['disk'][$title]['name'] = $value['device_name'][0];
to

Code: Select all

                $default_services['disk'][$title]['name'] = [$title];
Thought I'd put this out there if anyone else wants this.

Re: NCPA Wizard - Linux disk naming

Posted: Mon May 23, 2016 9:25 am
by mcapra
Thanks for sharing! I too tend to prefer the logical name :)

Re: NCPA Wizard - Linux disk naming

Posted: Tue Apr 11, 2017 3:16 pm
by vAJ
FYI. This fix no longer works with the new array built into v.1.4.x of the wizard.

Really not a fan of the verbose output of logical disks with NCPA 2.0.3. Makes using this wizard a pain for systems I add manually. Thankfully, most of my stuff is templated.

Re: NCPA Wizard - Linux disk naming

Posted: Tue Apr 11, 2017 5:02 pm
by avandemore
If you wish to write a custom wizard you can use this document as a guideline.

https://assets.nagios.com/downloads/nag ... ios-XI.pdf

Re: NCPA Wizard - Linux disk naming

Posted: Tue Apr 11, 2017 5:15 pm
by vAJ
It's not so much an issue with the Wizard as it is with NCPA.

The latest agent now lists every type of disk, far beyond mounted partitions of a Linux host. I just wanted to make sure that anyone who found this thread didn't assume the simple fix still works.

Re: NCPA Wizard - Linux disk naming

Posted: Wed Apr 12, 2017 9:30 am
by cdienger
Thanks for the input and sharing the work around. Was there anything else you wanted to point out or are we okay locking the thread?

Re: NCPA Wizard - Linux disk naming

Posted: Wed Apr 12, 2017 9:45 am
by vAJ
Lock it up.