Error adding plugin check_apachestatus

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
huyvinhptit
Posts: 5
Joined: Sat Jan 27, 2018 11:36 pm

Error adding plugin check_apachestatus

Post by huyvinhptit »

In the process of adding the plugin: check_apachestatus.pl to monitor the Apache state of ip 192.168.10.181 on the picture. I have configured the parameters on the picture according to the forum guidelines and faulty:

$ARG1$ = -p 443 -t 30 -w 20 -c 10

UNKNOWN 500 Can't connect to 192.168.10.181:443 (connect: Connection refused)


$ARG1$ = -p 80 -t 30 -w 20 -c 10
Similarly, when you leave -p 80 still UNKNOWN 404 error

If $ARG1$ = -s -t 30 -w 20 -c 10 is the error then: UNKNOWN
Loi1.JPG
Loi2.JPG
Loi3.JPG
If you have done anything about Nagios or have ever experienced this error, I hope to receive a share of fixes to the system to work normally.

Thank you very much !
You do not have the required permissions to view the files attached to this post.
bolson

Re: Error adding plugin check_apachestatus

Post by bolson »

From the command line of your Nagios XI server run the following and post the result:

Code: Select all

nmap 192.168.10.181
And similarly:

Code: Select all

wget http://192.168.10.181
wget https://192.168.10.181
huyvinhptit
Posts: 5
Joined: Sat Jan 27, 2018 11:36 pm

Re: Error adding plugin check_apachestatus

Post by huyvinhptit »

1.JPG
What I achieved is here. Hope you find the most effective way to fix it
You do not have the required permissions to view the files attached to this post.
huyvinhptit
Posts: 5
Joined: Sat Jan 27, 2018 11:36 pm

Re: Error adding plugin check_apachestatus

Post by huyvinhptit »

Can you help me !
kyang

Re: Error adding plugin check_apachestatus

Post by kyang »

The server you are checking, does it allow port 443 for https?

Your nmap is not showing 443.

Here's mine which shows 443.

Code: Select all

[root@localhost libexec]# nmap 192.168.4.125

Starting Nmap 6.47 ( http://nmap.org ) at 2018-03-05 11:18 CST
Nmap scan report for 192.168.4.125
Host is up (0.0000040s latency).
Not shown: 995 closed ports
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
443/tcp  open  https
3306/tcp open  mysql
5666/tcp open  nrpe
This is what I get when I run the check_apachestatus. (It works but throws unitialized errors.)

Code: Select all

[root@localhost libexec]# ./check_apachestatus.pl -H 192.168.4.125 -p 443
Use of uninitialized value $PosPreEnd in numeric le (<=) at ./check_apachestatus.pl line 166.
Use of uninitialized value $i in numeric le (<=) at ./check_apachestatus.pl line 166.
Use of uninitialized value $i in array element at ./check_apachestatus.pl line 167.
Use of uninitialized value $PosPreEnd in numeric le (<=) at ./check_apachestatus.pl line 166.
Use of uninitialized value $IdleWorkers in printf at ./check_apachestatus.pl line 185.
Use of uninitialized value $BusyWorkers in printf at ./check_apachestatus.pl line 185.
OK 0.029191 seconds response time. Idle 0, busy 0, open slots 1 | 0;0;0;0;0;3;2;3;0;2;1
Is check_http from our nagios-plugins package not an option for you?
Locked