start | The `start` action starts the Icinga 2 daemon.
stop | The `stop` action stops the Icinga 2 daemon.
restart | The `restart` action is a shortcut for running the `stop` action followed by `start`.
- reload | The `reload` action sends the HUP signal to Icinga 2 which causes it to restart. Unlike the `restart` action `reload` does not wait until Icinga 2 has restarted.
+ reload | The `reload` action sends the `HUP` signal to Icinga 2 which causes it to restart. Unlike the `restart` action `reload` does not wait until Icinga 2 has restarted.
checkconfig | The `checkconfig` action checks if the `/etc/icinga2/icinga2.conf` configuration file contains any errors.
status | The `status` action checks if Icinga 2 is running.
#### Config Include Path
When including files you can specify that the include search path should be
-checked. You can do this by putting your config file name in angle brackets
-like this:
+checked. You can do this by putting your configuration file name in angle
+brackets like this:
include <test.conf>
#### Config Files
-Using the `--config` option you can specify one or more config files. Config
-files are processed in the order they're specified on the command-line.
+Using the `--config` option you can specify one or more configuration files.
+Config files are processed in the order they're specified on the command-line.
#### Config Validation
> **Note**
>
> If you have previously used Icinga 1.x you may already be familiar with
-> user and argument macros (e.g., USER1 or ARG1). Unlike in Icinga 1.x macros
+> user and argument macros (e.g., `USER1` or `ARG1`). Unlike in Icinga 1.x macros
> may have arbitrary names and arguments are no longer specified in the
-> check_command setting.
+> `check_command` setting.
Macro names must be enclosed in two `$` signs, e.g. `$plugindir$`. When
executing commands Icinga 2 checks the following objects in this
> **Note**
>
-> Macros in capital letters (e.g. HOSTNAME) are reserved for use by Icinga 2
+> Macros in capital letters (e.g. `HOSTNAME`) are reserved for use by Icinga 2
> and should not be overwritten by users.
By convention every host should have an `address` macro. Hosts
Name | Description
-----------------------|--------------
HOSTNAME | The name of the host object.
- HOSTDISPLAYNAME | The value of the display_name attribute.
+ HOSTDISPLAYNAME | The value of the `display_name` attribute.
HOSTALIAS | This is an alias for the `HOSTDISPLAYNAME` macro.
- HOSTSTATE | The host's current state. Can be one of UNREACHABLE, UP and DOWN.
- HOSTSTATEID | The host's current state. Can be one of 0 (up), 1 (down) and 2 (unreachable).
- HOSTSTATETYPE | The host's current state type. Can be one of SOFT and HARD.
+ HOSTSTATE | The host's current state. Can be one of `UNREACHABLE`, `UP` and `DOWN`.
+ HOSTSTATEID | The host's current state. Can be one of `0` (up), `1` (down) and `2` (unreachable).
+ HOSTSTATETYPE | The host's current state type. Can be one of `SOFT` and `HARD`.
HOSTATTEMPT | The current check attempt number.
MAXHOSTATTEMPT | The maximum number of checks which are executed before changing to a hard state.
- LASTHOSTSTATE | The host's previous state. Can be one of UNREACHABLE, UP and DOWN.
- LASTHOSTSTATEID | The host's previous state. Can be one of 0 (up), 1 (down) and 2 (unreachable).
- LASTHOSTSTATETYPE | The host's previous state type. Can be one of SOFT and HARD.
+ LASTHOSTSTATE | The host's previous state. Can be one of `UNREACHABLE`, `UP` and `DOWN`.
+ LASTHOSTSTATEID | The host's previous state. Can be one of `0` (up), `1` (down) and `2` (unreachable).
+ LASTHOSTSTATETYPE | The host's previous state type. Can be one of `SOFT` and `HARD`.
HOSTLATENCY | The host's check latency.
HOSTEXECUTIONTIME | The host's check execution time.
HOSTOUTPUT | The last check's output.
Name | Description
-----------------------|--------------
SERVICEDESC | The short name of the service object.
- SERVICEDISPLAYNAME | The value of the display_name attribute.
+ SERVICEDISPLAYNAME | The value of the `display_name` attribute.
SERVICECHECKCOMMAND | This is an alias for the `SERVICEDISPLAYNAME` macro.
- SERVICESTATE | The service's current state. Can be one of OK, WARNING, CRITICAL, UNCHECKABLE and UNKNOWN.
- SERVICESTATEID | The service's current state. Can be one of 0 (ok), 1 (warning), 2 (critical), 3 (unknown) and 4 (uncheckable).
- SERVICESTATETYPE | The service's current state type. Can be one of SOFT and HARD.
+ SERVICESTATE | The service's current state. Can be one of `OK`, `WARNING`, `CRITICAL` and `UNKNOWN`.
+ SERVICESTATEID | The service's current state. Can be one of `0` (ok), `1` (warning), `2` (critical) and `3` (unknown).
+ SERVICESTATETYPE | The service's current state type. Can be one of `SOFT` and `HARD`.
SERVICEATTEMPT | The current check attempt number.
MAXSERVICEATTEMPT | The maximum number of checks which are executed before changing to a hard state.
- LASTSERVICESTATE | The service's previous state. Can be one of OK, WARNING, CRITICAL, UNCHECKABLE and UNKNOWN.
- LASTSERVICESTATEID | The service's previous state. Can be one of 0 (ok), 1 (warning), 2 (critical), 3 (unknown) and 4 (uncheckable).
- LASTSERVICESTATETYPE | The service's previous state type. Can be one of SOFT and HARD.
+ LASTSERVICESTATE | The service's previous state. Can be one of `OK`, `WARNING`, `CRITICAL` and `UNKNOWN`.
+ LASTSERVICESTATEID | The service's previous state. Can be one of `0` (ok), `1` (warning), `2` (critical) and `3` (unknown).
+ LASTSERVICESTATETYPE | The service's previous state type. Can be one of `SOFT` and `HARD`.
LASTSERVICESTATECHANGE | The last state change's timestamp.
SERVICELATENCY | The service's check latency.
SERVICEEXECUTIONTIME | The service's check execution time.
> **Note**
>
-> The Icinga 2 configuration format is agnostic to whitespaces and
+> The Icinga 2 configuration format is agnostic to white space characters and
> new-lines.
> **Note**
arbitrary ASCII characters using the backslash character (\\) followed
by an ASCII character in octal encoding.
-#### Multiline String Literals
+#### Multi-line String Literals
Strings spanning multiple lines can be specified by enclosing them in
{{{ and }}}.
The `default-host` and `test-host` objects are marked as templates
using the `template` keyword. Unlike ordinary objects templates are not
-instantiated at runtime. Parent objects do not necessarily have to be
+instantiated at run-time. Parent objects do not necessarily have to be
templates though in general they are.
> **Note**
}
Valid operators include +, -, * and /. The default precedence rules can be
-overriden by grouping expressions using parentheses:
+overridden by grouping expressions using parentheses:
{
check_interval ((15 * 60) / 2)