1
0
mirror of https://github.com/Tafkas/fritzbox-munin.git synced 2023-10-10 13:36:55 +02:00

Merge pull request #16 from bobvandevijver/separate-hosts

Fixes #15. Add support for separate hosts
This commit is contained in:
Christian Stade-Schuldt 2017-09-06 22:34:31 +02:00 committed by GitHub
commit 4e5ede6d12
9 changed files with 36 additions and 0 deletions

View File

@ -99,6 +99,26 @@ You can change the used locale by setting an environment variable in your plugin
env.locale en
## Different hosts for the fritzbox and your system
You can split the graphs of your fritzbox from the localhost graphs by following the next steps:
1. Use the following as your host configuration in `/etc/munin/munin.conf`
[home.yourhost.net;server]
address 127.0.0.1
use_node_name yes
[home.yourhost.net;fritzbox]
address 127.0.0.1
use_node_name no
2. Add the following to your munin-node configuration
env.host_name fritzbox
3. Restart your munin-node: `systemctl restart munin-node`
## Environment Settings
Do not forget to restart the munin-node daemon as described in step 3 of the installation instructions above.

View File

@ -38,6 +38,8 @@ def print_config():
print "graph_category network"
print "uptime.label uptime"
print "uptime.draw AREA"
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == "__main__":

View File

@ -50,6 +50,8 @@ def print_config():
print "temp.graph LINE1"
print "temp.min 0"
print "temp.info Fritzbox CPU temperature"
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == '__main__':

View File

@ -50,6 +50,8 @@ def print_config():
print "cpu.graph AREA"
print "cpu.min 0"
print "cpu.info Fritzbox CPU usage"
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == '__main__':

View File

@ -58,6 +58,8 @@ def print_config():
print "free.label free"
print "free.type GAUGE"
print "free.draw STACK"
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == '__main__':

View File

@ -82,6 +82,8 @@ def print_config():
print "usb.min 0"
print "usb.max 100"
print "usb.info Fritzbox usb devices power consumption"
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == '__main__':

View File

@ -71,6 +71,8 @@ def print_config():
print "maxup.negative maxdown"
print "maxup.draw LINE1"
print "maxup.info Maximum speed of the WAN interface."
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == "__main__":

View File

@ -62,6 +62,8 @@ def print_config():
print "graph_category system"
print "uptime.label uptime"
print "uptime.draw AREA"
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == '__main__':

View File

@ -52,6 +52,8 @@ def print_config():
print 'wifi.type GAUGE'
print 'wifi.graph LINE1'
print 'wifi.info Wifi Connections on 2.4 & 5 Ghz'
if os.environ.get('host_name'):
print "host_name " + os.environ['host_name']
if __name__ == '__main__':