[
{ type: install
  message: <<EOM
=== Configuration details ===
You can mostly follow the guide at:
https://observium.org/wiki/Installation

with the following notes:
- Installation directory is %%WWWDIR%%
- The following lines should be put in a file %%LOCALBASE%%/etc/cron.d/observium
  or alternatively /etc/cron.d/observium

# Run a complete discovery of all devices once every 6 hours
33	*/6	*	*	*	www	%%WWWDIR%%/observium-wrapper discovery >/dev/null 2>&1
# Run automated discovery of newly added devices every 5 minutes
*/5	*	*	*	*	www	%%WWWDIR%%/observium-wrapper discovery --host new >/dev/null 2>&1
# Run multithreaded poller wrapper every 5 minutes
*/5	*	*	*	*	www	%%WWWDIR%%/observium-wrapper poller >/dev/null 2>&1
# Run housekeeping script daily for syslog, eventlog and alert log
13	5	*	*	*	www	%%WWWDIR%%/housekeeping.php -ysel >/dev/null 2>&1
# Run housekeeping script daily for rrds, ports, orphaned entries in the database and performance data
47	4	*	*	*	www	%%WWWDIR%%/housekeeping.php -yrptb >/dev/null 2>&1

Notes:

- A minimal install can be created with the following steps and configuration file:

0: make sure apache and mysql are up and running.

1: create the database and a dbaccount with the following (my)SQL commands:

    CREATE DATABASE observium DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
    GRANT ALL PRIVILEGES ON observium.* TO 'observium'@'localhost' IDENTIFIED BY 'notSecure';

2: create config file starting with the sample config file

        cp %%WWWDIR%%/config.php.default %%WWWDIR%%/config.php

   and make sure to set at least the following fields:

        $config['db_host'] = 'localhost';
        $config['db_user'] = 'observium';
        $config['db_pass'] = 'notSecure';
        $config['db_name'] = 'observium';

3:  populate the admin user and initialize the database (as 'www' user):

        sudo -u www %%WWWDIR%%/discovery.php -u
        sudo -u www %%WWWDIR%%/adduser.php admin SomeInsecureAdminPassword 10

4:   and verify that collection is working:

        sudo -u www %%WWWDIR%%/discovery.php -h all -d
        sudo -u www %%WWWDIR%%/poller.php -h all -d

5: Install the above crontabs.

6: Edit the file

   %%PREFIX%%/%%APACHEETCDIR%%/Includes/observium.conf
   
   and fill out a port number and hostname, or use the
   default at port 8080.

7: restart the webserver with 

       service apache24 restart

   or stop/start if in case of IP or SSL changes.

6: log in with a web browser; using the username 'admin' and the
   password 'SomeInsecureAdminPassword'.

   Hosts can be added from the webinterface or from the commandline.

EOM
}
]
