2013-10-02 09:50:26 +02:00
|
|
|
## Setting up Icinga Classic UI
|
2013-09-27 10:44:24 +02:00
|
|
|
|
2013-10-07 09:35:44 +02:00
|
|
|
Icinga 2 can write `status.dat` and `objects.cache` files in the format that
|
2013-09-27 10:44:24 +02:00
|
|
|
is supported by the Icinga 1.x Classic UI. External commands (a.k.a. the
|
|
|
|
"command pipe") are also supported. It also supports writing Icinga 1.x
|
|
|
|
log files which are required for the reporting functionality in the Classic UI.
|
|
|
|
|
2013-10-02 09:50:26 +02:00
|
|
|
### Installing Icinga Classic UI
|
2013-09-27 10:44:24 +02:00
|
|
|
|
|
|
|
You can install Icinga 1.x Classic UI in standalone mode using the
|
|
|
|
following commands:
|
|
|
|
|
|
|
|
$ wget http://downloads.sourceforge.net/project/icinga/icinga/1.9.3/icinga-1.9.3.tar.gz
|
|
|
|
$ tar xzf icinga-1.9.3.tar.gz ; cd icinga-1.9.3
|
|
|
|
$ ./configure --enable-classicui-standalone --prefix=/usr/local/icinga2-classicui
|
|
|
|
$ make classicui-standalone
|
2013-10-02 14:23:31 +02:00
|
|
|
$ sudo make install-classicui-standalone install-webconf-auth
|
2013-09-27 10:44:24 +02:00
|
|
|
$ sudo service apache2 restart
|
|
|
|
|
|
|
|
> **Note**
|
|
|
|
>
|
|
|
|
> A detailed guide on installing Icinga 1.x Classic UI Standalone can be
|
|
|
|
> found on the Icinga Wiki here:
|
|
|
|
> [https://wiki.icinga.org/display/howtos/Setting+up+Icinga+Classic+UI+Standalone](https://wiki.icinga.org/display/howtos/Setting+up+Icinga+Classic+UI+Standalone)
|
|
|
|
|
2013-10-02 09:50:26 +02:00
|
|
|
### Configuring Icinga 2
|
2013-10-01 12:59:02 +02:00
|
|
|
|
2013-10-07 09:35:44 +02:00
|
|
|
By default Icinga 2 does not write `status.dat` and `objects.cache` files which are used
|
2013-10-01 12:59:02 +02:00
|
|
|
by the Classic UI. The command pipe is also not enabled by default.
|
|
|
|
|
|
|
|
You can use i2enfeature to enable these features:
|
|
|
|
|
|
|
|
# i2enfeature statusdat
|
|
|
|
# i2enfeature command
|
|
|
|
|
|
|
|
After enabling these features you will need to restart Icinga 2:
|
|
|
|
|
|
|
|
# /etc/init.d/icinga2 restart
|
|
|
|
|
2013-10-07 09:35:44 +02:00
|
|
|
You should be able to find the `status.dat` and `objects.cache` files in
|
|
|
|
`/var/cache/icinga2`. The log files can be found in `/var/log/icinga2/compat`.
|
|
|
|
The command pipe can be found in `/var/run/icinga2/cmd/icinga2.cmd`.
|
|
|
|
|
2013-10-02 09:50:26 +02:00
|
|
|
### Configuring the Classic UI
|
2013-09-27 10:44:24 +02:00
|
|
|
|
|
|
|
After installing the Classic UI you will need to update the following
|
2013-10-07 09:35:44 +02:00
|
|
|
settings in your `cgi.cfg` configuration file in the `STANDALONE (ICINGA 2)
|
|
|
|
OPTIONS` section:
|
2013-09-27 10:44:24 +02:00
|
|
|
|
|
|
|
Configuration Setting |Value
|
|
|
|
------------------------------------|------------------------------------
|
|
|
|
object\_cache\_file |/var/cache/icinga2/objects.cache
|
|
|
|
status\_file |/var/cache/icinga2/status.dat
|
|
|
|
resource\_file |-
|
2013-09-30 09:42:27 +02:00
|
|
|
command\_file |/var/run/icinga2/cmd/icinga2.cmd
|
2013-09-27 10:44:24 +02:00
|
|
|
check\_external\_commands |1
|
|
|
|
interval\_length |60
|
|
|
|
status\_update\_interval |10
|
|
|
|
log\_file |/var/log/icinga2/compat/icinga.log
|
|
|
|
log\_rotation\_method |h
|
|
|
|
log\_archive\_path |/var/log/icinga2/compat/archives
|
|
|
|
date\_format |us
|
|
|
|
------------------------------------ ------------------------------------
|
|
|
|
|
|
|
|
> **Note**
|
|
|
|
>
|
|
|
|
> Depending on how you installed Icinga 2 some of those paths and options
|
|
|
|
> might be different.
|
|
|
|
|
2013-10-01 15:33:34 +02:00
|
|
|
In order for commands to work you will need to add your web server user to
|
2013-10-07 09:35:44 +02:00
|
|
|
the `icingacmd` group:
|
2013-09-27 10:44:24 +02:00
|
|
|
|
2013-10-02 09:50:26 +02:00
|
|
|
# usermod -a -G icingacmd www-data
|
2013-09-27 10:44:24 +02:00
|
|
|
|
|
|
|
> **Note**
|
|
|
|
>
|
2013-10-07 09:35:44 +02:00
|
|
|
> Change `www-data` to the user name your web server is running as.
|
2013-09-27 10:44:24 +02:00
|
|
|
|
|
|
|
Verify that your Icinga 1.x Classic UI works by browsing to your Classic
|
|
|
|
UI installation URL, e.g.
|
|
|
|
[http://localhost/icinga](http://localhost/icinga)
|