ADMIN+Magazine+Sample+PDF
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Features<br />
Icinga<br />
Figure 3: A manual check of commands in commands.cfg reveals the culprit.<br />
Figure 4: Mail dispatched by Icinga is short and to the point.<br />
need to consider the interval between<br />
checks. One useful feature is the ability<br />
to define time slots, within which<br />
Icinga will perform checks and, if<br />
necessary, notify the administrator.<br />
Here, time limitations or holidays can<br />
be defined.<br />
The contact configuration can include<br />
email addresses or cell phone numbers,<br />
but to integrate each contact<br />
with, for example, an Email2SMS<br />
gateway or a Text2Speech system<br />
(e.g., Festival), you need a matching<br />
command.<br />
Icinga can use macros, which noticeably<br />
simplifies and accelerates many<br />
tasks because you can use a single<br />
command for multiple hosts and services.<br />
Listings 2 and 3 give examples<br />
of macros.<br />
All services defined for monitoring<br />
the file server include a check_nrpe<br />
instruction with an exclamation<br />
mark. Each exclamation mark can<br />
be followed by an argument, which<br />
in turn is evaluated by the macros in<br />
other definitions. Macros are nested<br />
in $ signs.<br />
After creating the configuration files<br />
and storing them in etc/objects, you<br />
still need to tell Icinga by adding a<br />
new<br />
Icinga with /etc/init.d/icinga restart.<br />
GUI and Messages<br />
Icinga works without a graphical<br />
interface, but it’s much nicer to have<br />
one. The standard interface can’t<br />
deny its Nagios ancestry, but it is<br />
clear-cut and intuitive.<br />
If everything is working, you’ll see a<br />
lot of green in the user interface (Figure<br />
1), but if something goes wrong<br />
somewhere, the color will change and<br />
move closer and closer to red to reflect<br />
the status of the hosts or services<br />
(Figures 2 and 3). Status messages<br />
are typically linked, so that clicking<br />
one takes you to more detailed information.<br />
If something is so drastically wrong<br />
that a message is necessary, Icinga<br />
will check its complex ruleset to see<br />
whether it should send a message<br />
and, if so, to whom (Figure 4). The<br />
filters through which the message<br />
passes check the following: whether<br />
notifications are required, if the<br />
problem occurred at a time when the<br />
host and service should be running,<br />
if messages should be sent for this<br />
service in the current time slot, and<br />
what the contacts linked to the service<br />
actually want. Each contact can<br />
cfg_file=/usr/local/icinga/etc/objects/<br />
object.cfg<br />
to the main configuration file, /etc/<br />
icinga.cfg. After doing so, you<br />
should verify the configuration,<br />
/path‐to‐Icinga/bin/icinga ‐v<br />
/path‐to‐Icinga/etc/icinga.cfg;<br />
assuming there are no errors, restart<br />
Figure 5: Icinga Web beta was not entirely convincing. Version 1.0.3 is out now.<br />
18 Admin 01 www.admin-magazine.com