Where can I put the Nagios plugins ?

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.
Locked
wangyu
Posts: 41
Joined: Tue Aug 25, 2015 2:41 am

Where can I put the Nagios plugins ?

Post by wangyu »

I install nagios in the /usr/local/nagios ,then I download the plugins check_TomcatApplication.sh from https://exchange.nagios.org/directory/P ... on/details

I put the plugin into the path /usr/local/nagios/libexec ,then I use the check_TomcatApplication.sh .
[root@VSLHAGILEAP01 libexec]# ./check_TomcatApplication.sh -u tomcat -p tomcat -h 10.202.16.70 -P 6666 -a host-manager
It show
[root@VSLHAGILEAP01 libexec]# ./check_TomcatApplication.sh -u tomcat -p tomcat -h 10.202.16.70 -P 6666 -a host-manager
Version 1.02

check_TomcatApplication is a Nagios plugin to check a specific Tomcat Application.

check_TomcatApplication -u user -p password -h host -P port -a application

Options:
-u/--user)
User name for authentication on Tomcat Manager Application
-p/--password)
Password for authentication on Tomcat Manager Application
-H/--host)
Host Name of the server
-P/--port)
Port Number Tomcat service is listening on
-a/--appname)
Application name to be checked
-V/--tomcat_version)
Version of the Tomcat. Default is Tomcat 6


Whether the plugins I put is wrong place .
Where is the plugins I should put ,then I can use it.
Thanks very much
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Where can I put the Nagios plugins ?

Post by Box293 »

wangyu wrote:I put the plugin into the path /usr/local/nagios/libexec
wangyu wrote:Whether the plugins I put is wrong place .
Where is the plugins I should put ,then I can use it.
You have put the plugin in the correct location.

I believe your issue has to do with the -h argument, it needs to be a capital -H
wangyu wrote:-H/--host)

Code: Select all

./check_TomcatApplication.sh -u tomcat -p tomcat -H 10.202.16.70 -P 6666 -a host-manager
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
wangyu
Posts: 41
Joined: Tue Aug 25, 2015 2:41 am

Re: Where can I put the Nagios plugins ?

Post by wangyu »

-h host

So I use the command:
[root@VSLHAGILEAP01 libexec]# ./check_TomcatApplication.sh -u tomcat -p tomcat -h SWHDTPLMTE01 -P 6666 -a host-manager
Version 1.02

check_TomcatApplication is a Nagios plugin to check a specific Tomcat Application.

check_TomcatApplication -u user -p password -h host -P port -a application

Options:
-u/--user)
User name for authentication on Tomcat Manager Application
-p/--password)
Password for authentication on Tomcat Manager Application
-H/--host)
Host Name of the server
-P/--port)
Port Number Tomcat service is listening on
-a/--appname)
Application name to be checked
-V/--tomcat_version)
Version of the Tomcat. Default is Tomcat 6

It continue can't work .
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Where can I put the Nagios plugins ?

Post by Box293 »

I've downloaded the plugin and read the code and it NEEDS a CAPITAL H.

This message it's reporting is a capitalisation error / spelling mistake:
wangyu wrote:check_TomcatApplication -u user -p password -h host -P port -a application
The help is correct:
wangyu wrote:-H/--host)
Host Name of the server
Try again with the capital H

Code: Select all

 ./check_TomcatApplication.sh -u tomcat -p tomcat -H SWHDTPLMTE01 -P 6666 -a host-manager
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
wangyu
Posts: 41
Joined: Tue Aug 25, 2015 2:41 am

Re: Where can I put the Nagios plugins ?

Post by wangyu »

It's OK now,thanks very much.

[root@VSLHAGILEAP01 libexec]# ./check_TomcatApplication.sh -u tomcat -p tomcat -H SWHDTPLMTE01 -P 6666 -a host-manager
OK: Application host-manager is running!
host-manager_JVM_OK:|host-manager_JVM_free=788743368MB;;;0 host-manager_JVM_total=810942464MB;;;0 host-manager_JVM_max=810942464MB;;;0
host-manager_http-6666 OK:|http-6666_maxTime=1425656ms;;;0 http-6666_processingTime=1429154ms;;;0 http-6666_requestCount=15ms;;;0 http-6666_errorCount=6ms;;;0 http-6666_bytesReceived=0ms;;;0 http-6666_bytesSent=85122ms;;;0
host-manager_ajp-6019 OK:|ajp-6019_maxTime=0ms;;;0 ajp-6019_processingTime=0ms;;;0 ajp-6019_requestCount=0ms;;;0 ajp-6019_errorCount=0ms;;;0 ajp-6019_bytesReceived=0ms;;;0 ajp-6019_bytesSent=0ms;;;0
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Where can I put the Nagios plugins ?

Post by hsmith »

wangyu wrote:It's OK now,thanks very much.

[root@VSLHAGILEAP01 libexec]# ./check_TomcatApplication.sh -u tomcat -p tomcat -H SWHDTPLMTE01 -P 6666 -a host-manager
OK: Application host-manager is running!
host-manager_JVM_OK:|host-manager_JVM_free=788743368MB;;;0 host-manager_JVM_total=810942464MB;;;0 host-manager_JVM_max=810942464MB;;;0
host-manager_http-6666 OK:|http-6666_maxTime=1425656ms;;;0 http-6666_processingTime=1429154ms;;;0 http-6666_requestCount=15ms;;;0 http-6666_errorCount=6ms;;;0 http-6666_bytesReceived=0ms;;;0 http-6666_bytesSent=85122ms;;;0
host-manager_ajp-6019 OK:|ajp-6019_maxTime=0ms;;;0 ajp-6019_processingTime=0ms;;;0 ajp-6019_requestCount=0ms;;;0 ajp-6019_errorCount=0ms;;;0 ajp-6019_bytesReceived=0ms;;;0 ajp-6019_bytesSent=0ms;;;0
Is this one all right to mark resolved, then? I'm assuming that's the output you want from the command.
Former Nagios Employee.
me.
Locked