it-novum / openITCOCKPIT

openITCOCKPIT is an Open Source system monitoring tool built for different monitoring engines like Nagios, Naemon and Prometheus.
https://openitcockpit.io/
GNU General Public License v3.0
263 stars 50 forks source link

ICMP checks not working #1676

Closed viktordw closed 4 months ago

viktordw commented 4 months ago

I have configured Debian12 monitoring server as described on your download page, and in the documentation: https://docs.openitcockpit.io/en/installation/

The installation was done without errors, and after running the script /opt/openitc/frontend/SETUP.sh, it completed with two errors:

chmod: cannot access '/opt/openitc/nagios/libexec/check_icmp': No such file or directory
chmod: cannot access '/opt/openitc/nagios/libexec/check_dhcp': No such file or directory

These errors were displayed because the entire nagios/ directory inside /opt/openitc/ is missing, so I can suspect that either some of the installation steps are not mentioned in the documentation, or the openitcockpit Debian package is missing some files.

After signing in to the web interface I added a new host as described here: https://docs.openitcockpit.io/en/beginners/create-first-host/

After that, in the Status overview section, there was another error related to the aforementioned check_icmp file.

(No output on stdout) stderr: execvp(/opt/openitc/nagios/libexec/check_icmp, ...) failed. errno is 2: No such file or directory

In the Service overview section, there is also the following message

Problem with host detected. Services output may not as expected!

Surprisingly, I didn't manage to find a similar issue, and there is nothing about this in the troubleshooting section in the documentation.

@nook24, @ibering Do you have some idea what might be causing the issue?

viktordw commented 4 months ago

Update: I have found a work-around, by additionally installing the monitoring-plugins package, and making a symlink from /usr/lib/nagios/plugins/check_icmp to /opt/openitc/nagios/libexec/check_icmp.

This seems to solve the issue, but I still wonder why default installation in not working.

Isn't your package supposed to install required plugins separately?

nook24 commented 4 months ago

Hi @viktordw, my guess is, that your apt is configured to not install recommended packages. openITCOCKPIT uses weak dependencies for some packages. The package openitcockpit-monitoring-plugins (that one that is missing on your system) is a package with weak dependencies. We recommend to use our openitcockpit-monitoring-plugins package, but it is not required and a user can go with the monitoring-plugins package that is provided by the Ubuntu Community.

Ubuntu and Debian are installing recommended packages by default. How ever, some cloud providers have disabled this in the apt configuration for some reason.

With the next release of openITCOCKPIT, we will also add a section about this in the documentation: https://github.com/it-novum/openITCOCKPIT-documentation/blob/577b6e07b512662f54dbd3629172eed43a0f12ab/en/docs/additional/troubleshooting.md#recommended-packages

https://raw.githubusercontent.com/it-novum/openITCOCKPIT-documentation/577b6e07b512662f54dbd3629172eed43a0f12ab/de/docs/images/troubleshooting/apt_recommended.jpg

viktordw commented 4 months ago

Thank you for your response.

You were right. I didn't check the "Recommended packages" section before running the installation.

While it might seem obvious, I think this is not appropriately stated in the documentation. Both the installation guide in the docs and download page of the website should mention this somewhere.

viktordw commented 4 months ago

Just to add to the previous comment, it's fine that this issue is mentioned in the Troubleshooting section of the docs, but I think that the main installation guide should point out this, so the new users won't need to search additional sections in the documentation.