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:[email protected]]
Sent: June-05-17 12:31 PM
To: [email protected]; 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 <[email protected]
<mailto:[email protected]> > 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
[email protected] <mailto:[email protected]>
http://lists.genieacs.com/mailman/listinfo/users
_______________________________________________
Users mailing list
[email protected]
http://lists.genieacs.com/mailman/listinfo/users