File: plugins.html

package info (click to toggle)
icinga 1.0.2-2%2Bsqueeze1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 33,952 kB
  • ctags: 13,294
  • sloc: xml: 154,821; ansic: 99,198; sh: 14,585; sql: 5,852; php: 5,126; perl: 2,838; makefile: 1,268
file content (157 lines) | stat: -rw-r--r-- 7,972 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Icinga Plugins</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.75.1">
<meta name="keywords" content="Supervision, Icinga, Nagios, Linux">
<link rel="home" href="index.html" title="Icinga Version 1.0.2 Documentation">
<link rel="up" href="ch05.html" title="Chapter 5. The Basics">
<link rel="prev" href="ch05.html" title="Chapter 5. The Basics">
<link rel="next" href="macros.html" title="Understanding Macros and How They Work">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<CENTER><IMG src="../images/logofullsize.png" border="0" alt="Icinga" title="Icinga"></CENTER>
<div class="navheader">
<table width="100%" summary="Navigation header">
<tr><th colspan="3" align="center">Icinga Plugins</th></tr>
<tr>
<td width="20%" align="left">
<a accesskey="p" href="ch05.html">Prev</a> </td>
<th width="60%" align="center">Chapter 5. The Basics</th>
<td width="20%" align="right"> <a accesskey="n" href="macros.html">Next</a>
</td>
</tr>
</table>
<hr>
</div>
<div class="section" title="Icinga Plugins">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
<a name="plugins"></a><a name="Icinga_plugins"></a>Icinga Plugins</h2></div></div></div>
  

  <p><span class="bold"><strong>Introduction</strong></span></p>

  <p>Unlike many other monitoring tools, Icinga does not include any internal mechanisms for checking the status of
  hosts and services on your network. Instead, Icinga relies on external programs (called plugins) to do all the dirty
  work.</p>

  <p><span class="bold"><strong>What Are Plugins?</strong></span></p>

  <p>Plugins are compiled executables or scripts (Perl scripts, shell scripts, etc.) that can be run from a command line to
  check the status or a host or service. Icinga uses the results from plugins to determine the current status of hosts and
  services on your network.</p>

  <p>Icinga will execute a plugin whenever there is a need to check the status of a service or host. The plugin does
  <span class="emphasis"><em>something</em></span> (notice the very general term) to perform the check and then simply returns the results to
  Icinga. Icinga will process the results that it receives from the plugin and take any necessary actions (running
  <a class="link" href="eventhandlers.html" title="Event Handlers">event handlers</a>, sending out <a class="link" href="notifications.html" title="Notifications">notifications</a>,
  etc).</p>

  <p><span class="bold"><strong>Plugins As An Abstraction Layer</strong></span></p>

  <p><span class="inlinemediaobject"><img src="../images/plugins.png"></span></p>

  <p>Plugins act as an abstraction layer between the monitoring logic present in the Icinga daemon and the actual
  services and hosts that are being monitored.</p>

  <p>The upside of this type of plugin architecture is that you can monitor just about anything you can think of. If you can
  automate the process of checking something, you can monitor it with Icinga. There are already a lot of plugins that have
  been created in order to monitor basic resources such as processor load, disk usage, ping rates, etc. If you want to monitor
  something else, take a look at the documentation on <a class="link" href="pluginapi.html" title="Icinga Plugin API">writing plugins</a> and roll your own. Its
  simple!</p>

  <p>The downside to this type of plugin architecture is the fact that Icinga has absolutely no idea what it is that
  you're monitoring. You could be monitoring network traffic statistics, data error rates, room temperate, CPU voltage, fan speed,
  processor load, disk space, or the ability of your super-fantastic toaster to properly brown your bread in the morning...
  Icinga doesn't understand the specifics of what's being monitored - it just tracks changes in the
  <span class="emphasis"><em>state</em></span> of those resources. Only the plugins themselves know exactly what they're monitoring and how to
  perform the actual checks.</p>

  <p><span class="bold"><strong>What Plugins Are Available?</strong></span></p>

  <p>There are plugins currently available to monitor many different kinds of devices and services, including:</p>

  <div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
      <p>HTTP, POP3, IMAP, FTP, SSH, DHCP</p>
    </li>
<li class="listitem">
      <p>CPU Load, Disk Usage, Memory Usage, Current Users</p>
    </li>
<li class="listitem">
      <p>Unix/Linux, Windows, and Netware Servers</p>
    </li>
<li class="listitem">
      <p>Routers and Switches</p>
    </li>
<li class="listitem">
      <p>etc.</p>
    </li>
</ul></div>

  <p><span class="bold"><strong>Obtaining Plugins</strong></span></p>

  <p>Plugins are not distributed with Icinga, but you can download the official Nagios plugins and many
  additional plugins created and maintained by Nagios and Icinga users from the following locations:</p>

  <div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
      <p>Nagios Plugins Project: <a class="link" href="http://nagiosplug.sourceforge.net/" target="_top">http://nagiosplug.sourceforge.net/</a></p>
    </li>
<li class="listitem">
      <p>Nagios Downloads Page: <a class="link" href="http://www.nagios.org/download/" target="_top">http://www.nagios.org/download/</a></p>
    </li>
<li class="listitem">
      <p>IcingaExchange.org: <a class="link" href="http://www.monitoringexchange.org" target="_top">http://www.monitoringexchange.org</a></p>
    </li>
</ul></div>

  <p><a name="plugins-howto"></a><span class="bold"><strong>How Do I Use Plugin X?</strong></span></p>

  <p>Most all plugins will display basic usage information when you execute them using '-h' or '--help' on the command line.
  For example, if you want to know how the check_http plugin works or what options it accepts, you should try executing the
  following command:</p>

  <pre class="screen"> ./check_http --help</pre>

  <div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../images/note.png"></td>
<th align="left">Note</th>
</tr>
<tr><td align="left" valign="top">
    <p>Always execute the plugin using the Icinga user because some plugins will create temporary files. If you're
    testing plugins with another user then the Icinga user may not have the permissions to overwrite existing files.</p>

    <p>Don't call the plugin using relative paths (i.e <span class="emphasis"><em>./check_test_plugin</em></span>). Always use absolute paths
    because that's the way $name-icinga; does it (i.e. <span class="emphasis"><em>/usr/local/icinga/libexec/check_test_plugin</em></span>).</p>
  </td></tr>
</table></div>

  <p><span class="bold"><strong>Plugin API</strong></span></p>

  <p>You can find information on the technical aspects of plugins, as well as how to go about creating your own custom plugins
  <a class="link" href="pluginapi.html" title="Icinga Plugin API">here</a>.</p>
  <a class="indexterm" name="id1964284"></a>
  <a class="indexterm" name="id1964296"></a>
</div>
<div class="navfooter">
<hr>
<table width="100%" summary="Navigation footer">
<tr>
<td width="40%" align="left">
<a accesskey="p" href="ch05.html">Prev</a> </td>
<td width="20%" align="center"><a accesskey="u" href="ch05.html">Up</a></td>
<td width="40%" align="right"> <a accesskey="n" href="macros.html">Next</a>
</td>
</tr>
<tr>
<td width="40%" align="left" valign="top">Chapter 5. The Basics </td>
<td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td>
<td width="40%" align="right" valign="top"> Understanding Macros and How They Work</td>
</tr>
</table>
</div>
<P class="copyright">© 2009-2010 Icinga Development Team, http://www.icinga.org</P>
</body>
</html>