# HG changeset patch # User Daniel O'Connor # Date 1420678708 -37800 # Node ID bf46efd061d793a9fc48c6f47ecb5afff1247495 # Parent a6297e8a42a36ceba6b8f8e1721dc92776ad50a4 Remove debugging and restore RRD update diff -r a6297e8a42a3 -r bf46efd061d7 adslstats.py --- a/adslstats.py Thu Jan 08 11:24:09 2015 +1030 +++ b/adslstats.py Thu Jan 08 11:28:28 2015 +1030 @@ -310,7 +310,7 @@ if options.verbose: print "Modem is offline" - if (options.update or options.munin) and stats != None: + if (options.update or options.munin != None) and stats != None: if options.update: try: os.stat(rrdname) @@ -318,14 +318,7 @@ if e.errno == 2: print "rrd not found, creating.." makerrd(rrdname) - - print '%d:%d:%d:%f:%f:%f:%f' % (int(time.time()), - stats.upstream, - stats.downstream, - stats.nmup, - stats.nmdown, - stats.attenup, - stats.attendown) + updaterrd(rrdname, int(time.time()), stats) if options.munin != None: if options.munin == 'signal': print '''noisemarginup.value %.1f