Warning: session_start(): open(/var/lib/php/sessions/sess_58055hbstnl797ph9pg6eqro5m, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
!7
// works with certain versions of vnstat. Try apt-get install vnstat
module EstimatedMonthlyTraffic > DynBigNumber {
switchable S vnstatInterface; // set this to the interface name if output is empty otherwise
start {
dm_reloadOnFieldChange vnstatInterface();
doEvery(0.0, 10*60.0, r {
if (!isOnPATH('vnstat))
setValue("vnstat not installed");
else
setValue(regexpReplaceWithNothing(",\\d+",
parse_vnstat(backtick("vnstat" + (empty(vnstatInterface) ? "" : " -i " + vnstatInterface))).thisMonthEstimated));
});
}
}