The NDOutils addon stores Nagios related data to MySQL database.
Create Database:
create database nagios default character set='utf8' default collate='utf8_general_ci'; grant SELECT, INSERT, UPDATE, DELETE on nagios.* to 'nagios'@'localhost' identified by 'secret';
Create tables:
cd /unpacked-src-folder/db ./installdb -u root -p rootpw -h localhost -d nagios
Source used: ndoutils-1.4b9
cd /unpacked-src-folder ./configure --enable-mysql --disable-pgsql make
As told by the README file, manual install the compiled programs and config files1):
cp src/ndomod-3x.o /usr/local/bin/ndomod.o cp src/ndo2db-3x /usr/local/bin/ndo2db cp config/ndomod.cfg /etc/nagios/ cp config/ndo2db.cfg /etc/nagios/
Place the ndo2db init script to /etc/rc.d/init.d/
Edit the /etc/nagios/ndomod.cfg to your needs. Normally set these:
output_type=unixsocket output=/var/lib/nagios/ndo2db.sock buffer_file=/var/lib/nagios/ndomod.tmp data_processing_options=-1
Edit the /etc/nagios/ndo2db.cfg to your needs. Normally set these:
socket_name=/var/lib/nagios/ndo2db.sock db_pass=secret
Enable Nagios to use NDO2DB addon by settings these in /etc/nagios/nagios.cfg:
event_broker_options=-1 broker_module=/usr/local/bin/ndomod.o config_file=/etc/nagios/ndomod.cfg