muninlite/examples/post-muninlite.ini
Lars Kruse f4518e5375 Change name of executable from "munin-node" to "muninlite"
Previously MuninLite tried to create a drop-in-replacement for
munin-node by using the same name.  But MuninLite behaves differently
and may even be used in parallel to a regular munin-node setup on a host,
thus it should use a distinct name.
2020-02-08 23:39:44 +01:00

41 lines
1.4 KiB
INI

#!/bin/sh
# 2007-06-07 Kai Ove Gran
#
# This script will configure and launch muninlite on floppyfw
# (http://www.zelow.no/floppyfw/. Keep in mind that you floppyfw will have to
# be compiled with support for inetd for this to work.
# You will also have to open tcp port 4949 from the host running munin.
#
# Please read about how to configure muninlite at:
# http://sourceforge.net/projects/muninlite
#
# Please read about how to configure munin at:
# http://munin.projects.linpro.no/
# If munin is running on a host outside your local network, you will have to
# move this line to your firewall.init and change x.x.x.x to the IP of the
# external host. IT IS NOT RECOMMENDED TO ALLOW CONNECTIONS TO YOUR FLOPPYFW
# FROM AN EXTERNAL HOST! This might be a security risk.
#iptables -A INPUT -p TCP --dport 4949 -s x.x.x.x -j ACCEPT
if [ -f /sbin/inetd ]; then
if grep "^lrrd" /etc/inetd.conf >/dev/null 2>&1; then
echo "muninlite can not start as lrrd is already in use"
exit 1
else
echo "lrrd stream tcp nowait root /usr/bin/muninlite" >> /etc/inetd.conf
fi
PID=$(ps | grep -v grep | grep inetd | sed 's/^ \{1,\}//' | cut -d\ -f1)
if [ ! -z "$PID" ]; then
echo "inetd already running.. restarting.."
kill -HUP $PID
else
echo "Starting inetd."
inetd /etc/inetd.conf
fi
else
echo "inetd not found, not installing muninlite"
fi