--- /dev/null
+#!/bin/sh
+
+if [ -e "/var/run/icinga2/cmd/icinga2.cmd" ];
+then
+ echo "Icinga2 commandpipe found"
+ exit 0
+else
+ echo "Icinga2 commandpipe not found"
+ exit 1
+fi
--- /dev/null
+#!/bin/sh
+
+if [ ! -e /var/run/icinga2/cmd/livestatus ];
+then
+ sudo icinga2-enable-feature livestatus 1> /dev/null
+ sudo service icinga2 restart 1> /dev/null
+ sleep 1
+
+ if [ ! -e /var/run/icinga2/cmd/livestatus ];
+ then
+ echo "Icinga2 Livestatus socket not found"
+ exit 1
+ fi
+fi
+
+echo "Icinga2 Livestatus socket found"
+exit 0
--- /dev/null
+#!/bin/sh
+
+if sudo test -f /var/log/icinga2/icinga2.log;
+then
+ echo "Icinga2 log file found"
+ exit 0
+else
+ echo "Icinga2 log file not found"
+ exit 1
+fi
--- /dev/null
+#!/bin/sh
+
+if [ -f /var/run/icinga2/icinga2.pid ];
+then
+ echo "Icinga2 pidfile found"
+ exit 0
+else
+ echo "Icinga2 pidfile not found"
+ exit 1
+fi
--- /dev/null
+#!/bin/sh
+
+if [ ! -f /var/cache/icinga2/status.dat ];
+then
+ sudo icinga2-enable-feature statusdata 1> /dev/null
+ sudo service icinga2 restart 1> /dev/null
+
+ n=0
+ while [ $n -lt 3 ]
+ do
+ sleep 15
+
+ if [ -f /var/cache/icinga2/status.dat ];
+ then
+ break
+ fi
+
+ n=$(( $n + 1))
+ done
+
+ if [ $n -eq 3 ];
+ then
+ echo "Icinga2 status.dat not found"
+ exit 1
+ fi
+fi
+
+echo "Icinga2 status.dat found"
+
+if [ -f /var/cache/icinga2/objects.cache ];
+then
+ echo "Icinga2 objects.cache found"
+ exit 0
+else
+ echo "Icinga2 objects.cache not found"
+ exit 1
+fi