I am trying to get the correct synxtax for a performance counter check. The printer queues exist but apparently I am missing something... Some help would be appreciated. This is a windows 2008 Server I am dealing with.
[root@ ~]# /usr/local/nagios/libexec/check_nrpe -H <servername> -t 60 -c CheckCounter -a "\Print Queue(BIS019PR01-Cold)\Jobs" MaxWarn=4 MaxCrit=6
No counters specified: add counter=<name of counter>
proper performance counter check syntax?
proper performance counter check syntax?
You do not have the required permissions to view the files attached to this post.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: proper performance counter check syntax?
You are missing Counter= from your command, it should be:
My example:
Using ShowAll adds more information:
You can also "Name" the output to something more friendly, this is done by adding the text between Counter and = using a colon (:), for example:
Code: Select all
/usr/local/nagios/libexec/check_nrpe -H <servername> -t 60 -c CheckCounter -a "Counter=\Print Queue(BIS019PR01-Cold)\Jobs" MaxWarn=4 MaxCrit=6Code: Select all
Command:
check_nrpe -H win2008r2-01 -c CheckCounter -a 'Counter=\Print Queue(Microsoft XPS Document Writer)\Jobs' MaxWarn=4 MaxCrit=6
Output:
OK all counters within bounds.|'\Print Queue(Microsoft XPS Document Writer)\Jobs'=0;4;6Code: Select all
Command:
check_nrpe -H win2008r2-01 -c CheckCounter -a 'Counter=\Print Queue(Microsoft XPS Document Writer)\Jobs' MaxWarn=4 MaxCrit=6 ShowAll
Output:
OK: \Print Queue(Microsoft XPS Document Writer)\Jobs: 0|'\Print Queue(Microsoft XPS Document Writer)\Jobs'=0;4;6Code: Select all
Command:
check_nrpe -H win2008r2-01 -c CheckCounter -a 'Counter:XPS Document Writer=\Print Queue(Microsoft XPS Document Writer)\Jobs' MaxWarn=4 MaxCrit=6 ShowAll
Output:
OK: XPS Document Writer: 0|'XPS Document Writer'=0;4;6As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: proper performance counter check syntax?
Thank you! This was very helpful!
Re: proper performance counter check syntax?
Do you have any further related questions emartine?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Re: proper performance counter check syntax?
Nope. We are good with this one. Please feel free to lock this.