$OpenBSD: README-main,v 1.7 2012/05/27 19:42:42 sthen Exp $

+-----------------------------------------------------------------------
| Running icinga-1.7.1 on OpenBSD
+-----------------------------------------------------------------------

Getting Started
===============

The main documentation for Icinga is provided in HTML format as part of
the icinga-cgi package, see /var/www/icinga-cgi/docs/en/index.html

The included sample configuration carries out some simple checks
on the local machine; these should work as-is.

You may check your configuration file format before starting Icinga:

	/usr/local/bin/icinga -v /etc/icinga/icinga.cfg

This will parse all configuration files and warn about any problems
which have been identified.

Upgrading from a previous version
=================================

If you are using IDODB, you will need to update the database schema.
See /var/www/icinga-cgi/docs/en/upgrading_idoutils.html or
http://docs.icinga.org/latest/en/upgrading_idoutils.html for more
information.

In 1.7.0, the IDO plugin was renamed from /usr/local/bin/idomod.o to
/usr/local/lib/idomod.so - change your broker_module setting in
/etc/icinga/icinga/icinga.cfg.

Chroot Considerations
=====================

If using OpenBSD's default chroot environment for httpd, some files
will need to be moved inside the jail and symbolic links created:

	mkdir -p /var/www/etc /var/www/var/log
	mv /etc/icinga/icinga /var/www/etc/
	ln -s /var/www/etc/icinga /etc/icinga
	mv /var/icinga /var/www/var/
	ln -s /var/www/var/icinga /var
	mv /var/log/icinga /var/www/var/log/
	ln -s /var/www/var/log/icinga /var/log

Web User-Interfaces
===================

Two web-based user interfaces are available for Icinga:

- icinga-cga: the classic (but improved) Nagios-style interface
- icinga-web: new API-based interface

At the time of writing, porting and packaging of icinga-web is
a work-in-progress.  To enable icinga-cgi, link the provided httpd.conf
snippet:

	ln -s ../modules.sample/icinga-cgi.conf /var/www/conf/modules

You may wish to modify this file.  By default it uses HTTP basic
authentication; you can create the password file as follows:

	touch /etc/icinga/icinga/htpasswd.users
	htpasswd /etc/icinga/icinga/htpasswd.users <username>

When done, restart the web server:

	/etc/rc.d/httpd restart

You should then be able to access the web interface at
http://localhost/icinga/

Moving from Nagios
==================

The configuration format is compatible with Nagios.  If you'd like
to move across with minimal changes, you can point Icinga at your
existing configuration files:

	echo 'icinga_flags="-d /etc/icinga/nagios/nagios.cfg"' >> /etc/rc.conf.local
	echo 'pkg_scripts="${pkg_scripts} icinga' >> /etc/rc.conf.local

You will need to merge the settings between Nagios' and Icinga's
cgi.cfg files.  sdiff(1), as used by sysmerge(8), can help with this.
main_config_file and some other settings (admin usernames etc) should
be taken from the Nagios file, whereas the various web-related settings
(url_html_path, physical_html_path, etc) need to point to the Icinga files.
