GenieACS
Dan Therrien
dan at mofinetwork.com
Mon Jun 5 12:52:44 EDT 2017
Hi Dan, Thank you for responding.
I see but this is assuming that the calculations are done on the device side. Always to focus them more on the server side if possible?
Say router has values in inform parameter for RX/TX, server somehow takes this and adds them to values already stored in database?
Just to clarify
1/ router’s diff bandwidth rx=500 tx=500
2/ Acs server already has values for rx/tx of 500
3/ server then takes routers values and adds them to database of rx=1000 tx=1000
Is it wise to access database outside Acs? I was thinking of PHP?
Is this possible?
Regards
Dan
From: Dan Morphis [mailto:dan at milkcarton.com]
Sent: June-05-17 12:31 PM
To: dan at mofinetwork.com; Community support for GenieACS users
Subject: Re: GenieACS
You can do something like this, changing the values to fit your needs. This script will refresh the parameters listed every 1.5 days. Create this as a provision script, then create a preset to run the provision.
log("Running Refresh_ATM_Stats");
let twoDays = 1.5 * (24 * (60 * 60) * 1000); //1.5 days
let twoDaysAgo = Date.now() - twoDays;
let paramNames = [
"InternetGatewayDevice.DeviceInfo.UpTime",
'InternetGatewayDevice.WANDevice.1.WANDSLInterfaceConfig.UpstreamCurrRate',
'InternetGatewayDevice.WANDevice.1.WANDSLInterfaceConfig.DownstreamCurrRate',
'InternetGatewayDevice.WANDevice.1.WANDSLInterfaceConfig.UpstreamMaxRate',
'InternetGatewayDevice.WANDevice.1.WANDSLInterfaceConfig.DownstreamMaxRate',
'InternetGatewayDevice.WANDevice.1.WANDSLInterfaceConfig.UpstreamNoiseMargin',
'InternetGatewayDevice.WANDevice.1.WANDSLInterfaceConfig.DownstreamNoiseMargin',
"InternetGatewayDevice.WANDevice.12.WANDSLInterfaceConfig.UpstreamCurrRate",
"InternetGatewayDevice.WANDevice.12.WANDSLInterfaceConfig.DownstreamCurrRate",
"InternetGatewayDevice.WANDevice.12.WANDSLInterfaceConfig.UpstreamMaxRate",
"InternetGatewayDevice.WANDevice.12.WANDSLInterfaceConfig.DownstreamMaxRate",
'InternetGatewayDevice.WANDevice.12.WANDSLInterfaceConfig.UpstreamNoiseMargin',
'InternetGatewayDevice.WANDevice.12.WANDSLInterfaceConfig.DownstreamNoiseMargin'
];
for(let key of paramNames) {
declare(key, {value: twoDaysAgo});
}
On Mon, Jun 5, 2017 at 6:57 AM, Dan Therrien <dan at mofinetwork.com <mailto:dan at mofinetwork.com> > wrote:
I’m trying to keep track of bandwidth usage and need some ideas.
I would like to have the router inform the genieACS server of the current value tx/rx and have the server retrieve that routers id and add that value as Bandwidth Usage. I don’t know where I would put this scripting.
Has anyone done this before?
Thanks
_______________________________________________
Users mailing list
Users at lists.genieacs.com <mailto:Users at lists.genieacs.com>
http://lists.genieacs.com/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.genieacs.com/pipermail/users/attachments/20170605/65b43786/attachment.html>
More information about the Users
mailing list