mirror of
https://github.com/Tafkas/fritzbox-munin.git
synced 2023-10-10 13:36:55 +02:00
Fixes #15. Add support for separate hosts
This commit is contained in:
parent
209eed91ae
commit
ca82415b78
20
README.md
20
README.md
@ -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.
|
||||
|
@ -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__":
|
||||
|
@ -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__':
|
||||
|
@ -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__':
|
||||
|
@ -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__':
|
||||
|
@ -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__':
|
||||
|
@ -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__":
|
||||
|
@ -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__':
|
||||
|
@ -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__':
|
||||
|
Loading…
Reference in New Issue
Block a user