Move host activity detection code to attic

This commit is contained in:
emanuele-f 2017-05-17 22:19:37 +02:00
parent 31893a28a8
commit 9c973ca439
34 changed files with 8582 additions and 942 deletions

View file

@ -1031,27 +1031,6 @@ end
-- ########################################################
function createActivityRRDCounter(path, verbose)
if(not(ntop.exists(path))) then
if(verbose) then io.write('Creating RRD '..path..'\n') end
local prefs = ntop.getPrefs()
local step = 300
local hb = step * 2
ntop.rrd_create(
path,
step,
'DS:in:DERIVE:'..hb..':U:U',
'DS:out:DERIVE:'..hb..':U:U',
'DS:bg:DERIVE:'..hb..':U:U',
'RRA:AVERAGE:0.5:1:'..tostring(prefs.host_activity_rrd_raw_hours*12),
'RRA:AVERAGE:0.5:12:'..tostring(prefs.host_activity_rrd_1h_days*24),
'RRA:AVERAGE:0.5:288:'..tostring(prefs.host_activity_rrd_1d_days)
)
end
end
-- ########################################################
function dumpSingleTreeCounters(basedir, label, host, verbose)
what = host[label]