3

I'm configuring Zabbix to monitor our servers. Zabbix is new to me. It is up and running, and monitoring works for some services.

One of our Centos servers has http running, so it seems logical to monitor that. I've added the "Template App HTTP Service" to the host. I used all default settings, didn't change anything. Now Zabbix reports that this service is down. The httpd service is running however, and I can open webpages.

How can I get Zabbix to monitor the HTTP service normally?

tshepang
  • 64,472
  • 86
  • 223
  • 290
SPRBRN
  • 1,117
  • 4
  • 20
  • 38
  • 1
    are you able to telnet to port 80 from the Zabbix server to the Centos server. Could it be a web server that only answers to port 443? – Rui F Ribeiro Nov 16 '15 at 09:42
  • Don't know about Zabbix as I've never touched it yet but with Nagios you can check the configuration to find out the actual commands it executes to determine the state of a service. Then you can run the command manually to check what Nagios sees and what output it receives. Maybe you could do the same with Zabbix? One possible trivial reason could be that the HTTP service is accessible from your location but not from the Zabbix host due to firewall rules. You can debug that and much more by following the procedure described above. – Erathiel Nov 16 '15 at 09:59
  • Oh, I think this belongs to ServerFault more than here :) – Erathiel Nov 16 '15 at 10:09
  • @RuiFRibeiro - you're right. This webserver is not reachable from outside the LAN, and the Zabbix server is outside that local network. I thought it would use a check similar to a commandline tool, but it doesn't. With other servers this works like it should, so this is a firewall matter. If you want to points you can make this an answer. – SPRBRN Nov 16 '15 at 10:13
  • done, as it will be more visible for others. – Rui F Ribeiro Nov 16 '15 at 10:22

2 Answers2

3

This is probably a firewall issue. We maintain here the Linux systems, and most of the time these kind of issues are due to the network team forgetting default firewall rules to new networks or new servers.

To debug the situation the best strategy is to try to telnet in the command line from the Zabbix/monitoring server to the web server in question.

Rui F Ribeiro
  • 55,929
  • 26
  • 146
  • 227
0

CURL Support Required:

The supplied URLs to the HTTP/S checks are tested using curl, and can fail if Zabbix is missing the required curl support. Zabbix Server has a dependency on cURL support per (at least) the latest Zabbix version 6.0 documentation:

To perform web monitoring Zabbix server must be initially configured with cURL (libcurl) support.

CHECKING CURL SUPPORT:

I checked my containerized Zabbix Server using:

ldd -v $(which libcurl)

which returned the following error because which returned an empty result as curl wasn't found:

ldd: missing file arguments

Conclusion:

Even if your checks and FW rules are all correct, without the required curl support you're dead in the water...

F1Linux
  • 2,286
  • 1
  • 16
  • 28