1. prereq
curl -s http://d01cid.ddns.net/sharel/bin/cid-upm | sh -s "nagios"
curl -s http://d01cid.ddns.net/sharel/bin/inst-httpd | sh
curl -s http://d01cid.ddns.net/sharel/bin/inst-mariadb-server | sh
2. installation
vi /etc/yum.repos.d/omd.repo
#
[omd]
name=omd
baseurl=http://labs.consol.de/repo/stable/rhel7/$basearch
enabled=1
gpgcheck=0
yum -y install omd
3. configuration
omd create remon
Adding /omd/sites/remon/tmp to /etc/fstab.
Creating temporary filesystem /omd/sites/remon/tmp...OK
Restarting Apache...OK
Created new site remon with version 2.60-labs-edition.
The site can be started with omd start remon.
The default web UI is available at http://srv121.d01.net/remon/
The admin user for the web applications is omdadmin with password omd.
Please do a su - remon for administration of this site.
![]() |
htpasswd -b -m /opt/omd/sites/remon/etc/htpasswd omdadmin admin |
omd config remon
or
runuser -l remon -c 'omd config set MYSQL on'
runuser -l remon -c 'omd config set SNMPTRAPD on'
runuser -l remon -c 'omd config set LIVESTATUS_TCP on'
runuser -l remon -c 'omd config set DEFAULT_GUI check_mk'
runuser -l remon -c 'omd config set CORE nagios'
omd start remon
Starting MySQL... first start of MySQL, creating initial database...
...OK.
Starting rrdcached...OK
Starting dedicated SNMPTrapd for site remon...OK
Starting npcd...OK
Starting nagios...OK
Starting dedicated Apache for site remon...OK
Starting xinetd...OK
Initializing Crontab...OK
omdadmin:omd
4. cli
omd status
Doing 'status' on site remon:
mysql: running
rrdcached: running
snmptrapd: running
npcd: running
nagios: running
apache: running
xinetd: running
crontab: running
-----------------------
Overall state: running
5. agent
curl -s http://d01cid.ddns.net/sharel/bin/inst-snmpd | sh
yum -y install http://d01cid.ddns.net/sharel/img/omd/check-mk-agent-1.2.8p20-1.noarch.rpm
// yum -y update check-mk-agent
![]() |
only install waitmax if /usr/bin/timeout is missing |
wget -nv http://d01cid.ddns.net/sharel/bin/waitmax-$(uname -i) -O /usr/bin/waitmax
6. advanced configuration
redirect status.dat to http server
mkdir -p /var/www/html/nagios
ln -sv /omd/sites/remon/tmp/icinga/status.dat /var/www/html/nagios/
create port 33333 to get status.dat
wget -N -nv http://d01cid.ddns.net/sharel/etc/xinetd.d/nagios -P /etc/xinetd.d/
cube /etc/xinetd.d/nagios "%user%" with "remon"
source /bin/cid-functions; cid_add_line /etc/services "nagios 33333/tcp"
systemctl restart xinetd.service
read the UNIX-socket
yum install naemon-livestatus
echo 'GET hosts' | unixcat /omd/sites/remon/tmp/run/live
echo 'GET services' | unixcat /omd/sites/remon/tmp/run/live
echo 'GET log' | unixcat /omd/sites/remon/tmp/run/live | awk -F';' '{print $239,$240}'
7. debugging
runuser -l remon -c 'omd config set CORE nagios'
ssh root@srv002 systemctl restart xinetd.service
yum -y install python-pillow