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

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
JumpingSnake
Posts: 30
Joined: Thu Apr 19, 2012 9:19 am

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

Post 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?
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

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

Post 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.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

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

Post 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
	}
Be sure to check out our Knowledgebase for helpful articles and solutions!
JumpingSnake
Posts: 30
Joined: Thu Apr 19, 2012 9:19 am

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

Post 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!
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

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

Post 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..
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

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

Post 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?
Nagios XI 5.8.1
https://outsideit.net
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

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

Post by lmiltchev »

Should I make a feature request for this?
Please, do so that it "won't fall in the cracks". Thanks!
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

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

Post by WillemDH »

Just created the feature request http://tracker.nagios.com/view.php?id=471

Thanks for looking into this.
Nagios XI 5.8.1
https://outsideit.net
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

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

Post by slansing »

Excellent, thank you Willem!
Locked