Page 1 of 1

Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Wed Jul 24, 2013 2:50 pm
by JumpingSnake
I'm sure I'm missing something, but I'll do my best to explain the situation:

I'm currently running NagiosXI in a VM (version 2012R2.2) on CentOS. When I click on the "Metrics" button on the Home page, it brings me into the Metrics area. When I try to look at anything dealing with my Linux servers (Load, Disk Usage, Swap), the Summary works great! However, when I try to use any of the Windows metrics (CPU Usage, Disk Usage, Memory Usage), nothing comes up.

I read in this previous post http://support.nagios.com/forum/viewtop ... 9bc#p35798 that the metrics are using specific services to do this, which is why you need to use Load instead of CPU Usage for Linux/Windows systems. I'm using NRPE which makes calls for the service as "alias_disk", etc. Since this isn't one of the usual "check_cpu_stats" or something similar, is this breaking the Metrics from working for my Windows boxes?

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Wed Jul 24, 2013 3:03 pm
by slansing
Yes the Metrics component is limited to data returned only by it's expected checks/services. For instance, I am able to pull up a gauge for CPU usage on a Windows server because the check that service is running is a standard/basic nsclient++ check_nt check against the CPU. This sounds like what you are running into.

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Wed Jul 24, 2013 3:09 pm
by lmiltchev
The metrics component is very particular. You must be using the "default" Windows Agent and it will show CPU for Windows. If you had a config, similar to this one, it would work:

Code: Select all

define service {
	host_name			Windows7
	service_description		CPU Usage
	use				xiwizard_windowsdesktop_nsclient_service
	check_command			check_xi_service_nsclient!password!CPULOAD!-l 5,80,90
	max_check_attempts		5
	check_interval			5
	retry_interval			1
	check_period			xi_timeperiod_24x7
	notification_interval		60
	first_notification_delay	0
	notification_period		xi_timeperiod_24x7
	notifications_enabled		0
	contacts			nagiosadmin
	_xiwizard			windowsserver
	register			1
	}

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Wed Jul 24, 2013 3:57 pm
by JumpingSnake
Ah, it sounds like t's a failure on my part to setup my Windows monitoring correctly.

Here's a copy of the config for the script that returns the Windows CPU usage:

Code: Select all

###############################################################################
#
# Service configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date:       2013-07-11 19:52:10
# Version:    Nagios 3.x config file
#
# --- DO NOT EDIT THIS FILE BY HAND ---
# Nagios QL will overwite all manual settings during the next update
#
###############################################################################

define service {
        service_description             CPU
        hostgroup_name                  Server-Windows
        display_name                    CPU
        check_command                   check_nrpe!alias_cpu!!!!!!!
        initial_state                   u
        max_check_attempts              7
        check_interval                  5
        retry_interval                  1
        first_notification_delay        1440
        notification_options            w,c,u,r,
        notifications_enabled           0
        register                        1
        }

###############################################################################
#
# Service configuration file
#
# END OF FILE
#
###############################################################################
So since my command isn't in the "check_xi_service_nsclient" form, it will not return correct for Metrics, but will for regular graphs, etc. Cool, thanks for helping me understand this! I'll have to search for any guides on how to setup NRPE to work "better" with NagiosXI as I must've missed it the first time. Any links you guys have for this would be appreciated and I'll try to post any that I find as well. Thanks again!

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Wed Jul 24, 2013 4:10 pm
by slansing
No problem, if you run the windows monitoring wizard you will see a number of the new service's shown for their respective checks in the Metrics component, such as CPU, Memory, etc..

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Tue Nov 26, 2013 5:10 am
by WillemDH
Is there any chance the metrics component will ever work with check_nrpe? As nrpe gives more options for cpu checking, I'm not using check_nt. But I would love to have some metrics in order to see the top 20 cpu consumers etc. I also use our own naming conventions.
Should I make a feature request for this?

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Tue Nov 26, 2013 1:56 pm
by lmiltchev
Should I make a feature request for this?
Please, do so that it "won't fall in the cracks". Thanks!

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Tue Nov 26, 2013 5:30 pm
by WillemDH
Just created the feature request http://tracker.nagios.com/view.php?id=471

Thanks for looking into this.

Re: Nagios XI - Metrics - Windows Services Don't Show Stats

Posted: Wed Nov 27, 2013 12:42 pm
by slansing
Excellent, thank you Willem!