mirror of
https://github.com/Tafkas/fritzbox-munin.git
synced 2023-10-10 13:36:55 +02:00
Fixes #13. Configurable traffic maximum
This commit is contained in:
parent
2c05d20602
commit
c1b1d4bffa
@ -27,6 +27,10 @@ If you are using the scripts on a different Fritz!Box model please let me know b
|
|||||||
fritzbox\_traffic shows you the traffic of the WAN interface (requires fritzconnection)
|
fritzbox\_traffic shows you the traffic of the WAN interface (requires fritzconnection)
|
||||||
![http://i.imgur.com/8BwNMOL.png](http://i.imgur.com/8BwNMOL.png)
|
![http://i.imgur.com/8BwNMOL.png](http://i.imgur.com/8BwNMOL.png)
|
||||||
|
|
||||||
|
If you do not want to show the interface maximum values, add the following to your plugin-configuration:
|
||||||
|
|
||||||
|
env.traffic_remove_max true
|
||||||
|
|
||||||
## fritzbox\_connection\_uptime
|
## fritzbox\_connection\_uptime
|
||||||
|
|
||||||
fritzbox\_connection\_uptime shows you the connection uptime in days (requires fritzconnection)
|
fritzbox\_connection\_uptime shows you the connection uptime in days (requires fritzconnection)
|
||||||
|
@ -32,6 +32,7 @@ def print_values():
|
|||||||
up_traffic = conn.call_action('WANCommonInterfaceConfig', 'GetTotalBytesSent')['NewTotalBytesSent']
|
up_traffic = conn.call_action('WANCommonInterfaceConfig', 'GetTotalBytesSent')['NewTotalBytesSent']
|
||||||
print ('up.value %d' % up_traffic)
|
print ('up.value %d' % up_traffic)
|
||||||
|
|
||||||
|
if not os.environ.get('traffic_remove_max'):
|
||||||
max_down_traffic = conn.call_action('WANCommonInterfaceConfig', 'GetCommonLinkProperties')[
|
max_down_traffic = conn.call_action('WANCommonInterfaceConfig', 'GetCommonLinkProperties')[
|
||||||
'NewLayer1DownstreamMaxBitRate']
|
'NewLayer1DownstreamMaxBitRate']
|
||||||
print ('maxdown.value %d' % max_down_traffic)
|
print ('maxdown.value %d' % max_down_traffic)
|
||||||
@ -61,6 +62,7 @@ def print_config():
|
|||||||
print "up.max 1000000000"
|
print "up.max 1000000000"
|
||||||
print "up.negative down"
|
print "up.negative down"
|
||||||
print "up.info Traffic of the WAN interface."
|
print "up.info Traffic of the WAN interface."
|
||||||
|
if not os.environ.get('traffic_remove_max'):
|
||||||
print "maxdown.label received"
|
print "maxdown.label received"
|
||||||
print "maxdown.type GAUGE"
|
print "maxdown.type GAUGE"
|
||||||
print "maxdown.graph no"
|
print "maxdown.graph no"
|
||||||
|
Loading…
Reference in New Issue
Block a user