File: verifyconfig.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 (94 lines) | stat: -rw-r--r-- 4,439 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
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Verifying Your Configuration</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="ch04.html" title="Chapter 4. Running Icinga">
<link rel="prev" href="ch04.html" title="Chapter 4. Running Icinga">
<link rel="next" href="startstop.html" title="Starting and Stopping Icinga">
</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">Verifying Your Configuration</th></tr>
<tr>
<td width="20%" align="left">
<a accesskey="p" href="ch04.html">Prev</a> </td>
<th width="60%" align="center">Chapter 4. Running Icinga</th>
<td width="20%" align="right"> <a accesskey="n" href="startstop.html">Next</a>
</td>
</tr>
</table>
<hr>
</div>
<div class="section" title="Verifying Your Configuration">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
<a name="verifyconfig"></a><a name="verify_config"></a>Verifying Your Configuration</h2></div></div></div>
  

  <p>Every time you modify your configuration files, you also have to restart Icinga. It is important to run a sanity check on
  your configuration files because in case of an error Icinga will not be (re)started.</p>

  <p>In order to verify your configuration, run Icinga using the <span class="bold"><strong>-v</strong></span> command line option:</p>

  <pre class="programlisting"> #&gt; /usr/local/icinga/bin/icinga -v /usr/local/icinga/etc/icinga.cfg  </pre>

  <p>If you've forgotten to enter some critical data or misconfigured things, Icinga will show a warning or error message that
  should point you to the location of the problem.</p>

  <p>Error messages generally print out the line in the configuration file that seems to be the source of the problem.</p>

  <p>On errors, Icinga will often exit the pre-flight check and return to the command prompt after printing only the first error
  that it has encountered.</p>

  <p>This is done because one error might lead to consecutive errors as the remainder of the configuration data is verified.</p>

  <p>If you get any error messages you'll need to go and edit your configuration files to remedy the problem. Warning messages can
  <span class="emphasis"><em>generally</em></span> be safely ignored, since they are only recommendations and not requirements.</p>

  <p>Instead of specifying the paths to binary and config file you can issue </p>
<pre class="programlisting"> #&gt; /etc/init.d/icinga checkconfig</pre>
<p>which
  results in just a non-zero return code if your config contains any errors. This might be useful if you want to restart Icinga
  automatically.</p>

  <p>Using </p>
<pre class="programlisting"> #&gt; /etc/init.d/icinga show-errors</pre>
<p>the command will create a file containing the errors found.
  If there are any the contents of the file is shown ("show-errors" starting with Icinga 1.0.2).</p>

  <p>Once you've verified your configuration files and fixed possible errors you can go ahead with <a class="xref" href="startstop.html" title="Starting and Stopping Icinga">“Starting and Stopping Icinga”</a>.</p>

  <a class="indexterm" name="id1963680"></a>

  <a class="indexterm" name="id1963695"></a>

  <a class="indexterm" name="id1963710"></a>

  <a class="indexterm" name="id1963723"></a>

  <a class="indexterm" name="id1963737"></a>
</div>
<div class="navfooter">
<hr>
<table width="100%" summary="Navigation footer">
<tr>
<td width="40%" align="left">
<a accesskey="p" href="ch04.html">Prev</a> </td>
<td width="20%" align="center"><a accesskey="u" href="ch04.html">Up</a></td>
<td width="40%" align="right"> <a accesskey="n" href="startstop.html">Next</a>
</td>
</tr>
<tr>
<td width="40%" align="left" valign="top">Chapter 4. Running Icinga </td>
<td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td>
<td width="40%" align="right" valign="top"> Starting and Stopping Icinga</td>
</tr>
</table>
</div>
<P class="copyright">© 2009-2010 Icinga Development Team, http://www.icinga.org</P>
</body>
</html>