Hello. First of all, sorry, if I created this topic in wrong category, but for me it seems to be the best. Anyway, I have two Ubuntu 16.04 machines, one is master setup and one satellite, where I installed Icinga2 and also IcingaWeb2 on master machine. To do so, I followed these tutorials:
Now I would like to add plugin called âcheck_logfilesâ (couldnât post more than 2 links, but it seems to be pretty popular plugin, so you should know which one I mean) and display its output in the IcingaWeb2. How to do it? I tried to search for different tutorials and guides, but there seems to be very little Icinga2 tutorials in the WebâŚ
What I tried to do, is copying check_logfiles plugin to /usr/lib/nagios/plugins, then created check_logfiles.cfg in /etc/nagios-plugins/config and defined command for it, then added it to my services.conf for satellite server, but when I run âicinga2 daemon - Câ to see if everything works properly, I am facing âError: Validation failed for object âsatellite!check_logfilesâ of type âServiceâ; Attribute âcheck_commandâ: Object âcheck_logfilesâ of type âCheckCommandâ does not exist.â.
Any guide on how to add plugin to both master and satellite servers and making it visible in IcingaWeb2 is welcomed.
Hello
The path you used is all nice and good if you use Nagios, however Icinga does not reas the /etc/nagios-plugins directory, it has itâs own ITL (Icinga Template Library) where the âbuilt-inâ commands and plugins are defined.
You can always define a new command & matching plugins in the configuration file, but it needs to end in *.conf.
To understand how to define a plugin, take a look at the documentation https://icinga.com/docs/icinga2/latest/doc/09-object-types/#checkcommand
The issue of display is not something you need to worry about, really.
Any check performed by Icinga is written the the database and the Web reads the data from that source and then presents it.
Iâve revamped the service monitoring chapter with many new details on adding custom plugins into your monitoring for 2.11.
Skip the parts with check-logfils.cfg into nagios-plugins, that is the old 1.x world and wonât work with Icinga. The guide youâre linking is wrong, better follow along in the official docs.
The cool thing here - the Icinga Template Library already provides the CheckCommand logfiles for your convenience. You just need to install the plugin into PluginDir, and create your service object definition.
i would really appreciate a hint/link how to include this check with Icinga2 director
everything is ok as log as i use the command from the command line
within Icinaga2 the only mssage i get back is:
Plugin-Ausgabe
Icinga 2 has been running for 5 minutes and 23 seconds. Version: r2.12.3-1
and even that is wrong, Icinga is running for 10 minutesâŚ
Hi and welcome.
Instead of âdigging up the deadâ , please open a new thread and explain your problem as detailed as possible.
Post info about your os, version of icinga and itâs components and used modules, provide screenshots and/or config snippets (use markdown formatting)