gigawords and bandwith
Hi, i'm new here and i need your help in the following 2 points. Point 1: Acct-Input/Output-Gigawords Point 2: Bandwithlimit with PPP and PPPoE My system: debian with kernel 2.6.8-2-386, Roaring Penguin PPPoE Version 3.10, PPP 2.4.4 (not quit sure) and MySQL 4.1.10a. Point 1) After I recognized that the accounting data (acct-input/output-octet) will set to zero if the user downloaded more than 4 GB I added to sql.conf and to table radacct the parameter acct-input/output-gigawords. But It won't be filled with data, it's always zero. The sql statements look like this ({acct_table1} and {acct_table2} are both radacct) accounting_update_query = "UPDATE ${acct_table1} \ SET FramedIPAddress = '%{Framed-IP-Address}', \ AcctSessionTime = '%{Acct-Session-Time}', \ AcctInputOctets = '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ AcctOutputOctets = '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}' \ WHERE AcctSessionId = '%{Acct-Session-Id}' \ AND UserName = '%{SQL-User-Name}' \ AND NASIPAddress= '%{NAS-IP-Address}'" accounting_stop_query = "UPDATE ${acct_table2} \ SET AcctStopTime = '%S', \ AcctSessionTime = '%{Acct-Session-Time}', \ AcctInputOctets = '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ AcctOutputOctets = '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ AcctTerminateCause = '%{Acct-Terminate-Cause}', \ AcctStopDelay = '%{Acct-Delay-Time}', \ ConnectInfo_stop = '%{Connect-Info}' \ WHERE AcctSessionId = '%{Acct-Session-Id}' \ AND UserName = '%{SQL-User-Name}' \ AND NASIPAddress = '%{NAS-IP-Address}'" accounting_stop_query_alt = "INSERT into ${acct_table2} \ (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, \ NASPortId, NASPortType, AcctStartTime, AcctStopTime, AcctSessionTime, \ AcctAuthentic, ConnectInfo_start, ConnectInfo_stop, AcctInputOctets, \ AcctOutputOctets, CalledStationId, CallingStationId, AcctTerminateCause, \ ServiceType, FramedProtocol, FramedIPAddress, AcctStartDelay, AcctStopDelay) \ values('%{Acct-Session-Id}', '%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', \ '%{Realm}', '%{NAS-IP-Address}', '%{NAS-Port}', '%{NAS-Port-Type}', \ DATE_SUB('%S', INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0}) SECOND), \ '%S', '%{Acct-Session-Time}', '%{Acct-Authentic}', '', '%{Connect-Info}', \ '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ '%{Called-Station-Id}', '%{Calling-Station-Id}', '%{Acct-Terminate-Cause}', \ '%{Service-Type}', '%{Framed-Protocol}', '%{Framed-IP-Address}', '0', '%{Acct-Delay-Time}')" accounting_update_query_alt = "INSERT into ${acct_table1} \ (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, \ NASPortId, NASPortType, AcctStartTime, AcctSessionTime, \ AcctAuthentic, ConnectInfo_start, AcctInputOctets, AcctOutputOctets, \ CalledStationId, CallingStationId, ServiceType, FramedProtocol, \ FramedIPAddress, AcctStartDelay) values('%{Acct-Session-Id}', \ '%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', '%{Realm}', \ '%{NAS-IP-Address}', '%{NAS-Port}', '%{NAS-Port-Type}', \ DATE_SUB('%S',INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0}) SECOND), \ '%{Acct-Session-Time}', '%{Acct-Authentic}', '', \ '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ '%{Called-Station-Id}', '%{Calling-Station-Id}', '%{Service-Type}', \ '%{Framed-Protocol}', '%{Framed-IP-Address}', '0')" Point 2) I have to limit the user's bandwith so I think about a simple possibility to do that. The best way imho would be a entry in "radreplay" for this user. I added there e.g. framed-ip-address. Is it possible? And if yes: How? Regards Lars
What ver of radius u running? Andrew Paternoster andrew@gpk.net.au Senior System Engineer GPK Computers Pty. Ltd. A.B.N 72 075 618 012 P.O. 407 Mt Evelyn Melbourne, VIC 3796 Australia Tel: 1300 854 223 Fax: 1300 854 223 ________________________________ -----Original Message----- From: freeradius-devel-bounces+andrew=gpk.net.au@lists.freeradius.org [mailto:freeradius-devel-bounces+andrew=gpk.net.au@lists.freeradius.org] On Behalf Of Lars Sent: Wednesday, 18 March 2009 10:39 PM To: freeradius-devel@lists.freeradius.org Subject: gigawords and bandwith Hi, i'm new here and i need your help in the following 2 points. Point 1: Acct-Input/Output-Gigawords Point 2: Bandwithlimit with PPP and PPPoE My system: debian with kernel 2.6.8-2-386, Roaring Penguin PPPoE Version 3.10, PPP 2.4.4 (not quit sure) and MySQL 4.1.10a. Point 1) After I recognized that the accounting data (acct-input/output-octet) will set to zero if the user downloaded more than 4 GB I added to sql.conf and to table radacct the parameter acct-input/output-gigawords. But It won't be filled with data, it's always zero. The sql statements look like this ({acct_table1} and {acct_table2} are both radacct) accounting_update_query = "UPDATE ${acct_table1} \ SET FramedIPAddress = '%{Framed-IP-Address}', \ AcctSessionTime = '%{Acct-Session-Time}', \ AcctInputOctets = '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ AcctOutputOctets = '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}' \ WHERE AcctSessionId = '%{Acct-Session-Id}' \ AND UserName = '%{SQL-User-Name}' \ AND NASIPAddress= '%{NAS-IP-Address}'" accounting_stop_query = "UPDATE ${acct_table2} \ SET AcctStopTime = '%S', \ AcctSessionTime = '%{Acct-Session-Time}', \ AcctInputOctets = '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ AcctOutputOctets = '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ AcctTerminateCause = '%{Acct-Terminate-Cause}', \ AcctStopDelay = '%{Acct-Delay-Time}', \ ConnectInfo_stop = '%{Connect-Info}' \ WHERE AcctSessionId = '%{Acct-Session-Id}' \ AND UserName = '%{SQL-User-Name}' \ AND NASIPAddress = '%{NAS-IP-Address}'" accounting_stop_query_alt = "INSERT into ${acct_table2} \ (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, \ NASPortId, NASPortType, AcctStartTime, AcctStopTime, AcctSessionTime, \ AcctAuthentic, ConnectInfo_start, ConnectInfo_stop, AcctInputOctets, \ AcctOutputOctets, CalledStationId, CallingStationId, AcctTerminateCause, \ ServiceType, FramedProtocol, FramedIPAddress, AcctStartDelay, AcctStopDelay) \ values('%{Acct-Session-Id}', '%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', \ '%{Realm}', '%{NAS-IP-Address}', '%{NAS-Port}', '%{NAS-Port-Type}', \ DATE_SUB('%S', INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0}) SECOND), \ '%S', '%{Acct-Session-Time}', '%{Acct-Authentic}', '', '%{Connect-Info}', \ '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ '%{Called-Station-Id}', '%{Calling-Station-Id}', '%{Acct-Terminate-Cause}', \ '%{Service-Type}', '%{Framed-Protocol}', '%{Framed-IP-Address}', '0', '%{Acct-Delay-Time}')" accounting_update_query_alt = "INSERT into ${acct_table1} \ (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, \ NASPortId, NASPortType, AcctStartTime, AcctSessionTime, \ AcctAuthentic, ConnectInfo_start, AcctInputOctets, AcctOutputOctets, \ CalledStationId, CallingStationId, ServiceType, FramedProtocol, \ FramedIPAddress, AcctStartDelay) values('%{Acct-Session-Id}', \ '%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', '%{Realm}', \ '%{NAS-IP-Address}', '%{NAS-Port}', '%{NAS-Port-Type}', \ DATE_SUB('%S',INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0}) SECOND), \ '%{Acct-Session-Time}', '%{Acct-Authentic}', '', \ '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ '%{Called-Station-Id}', '%{Calling-Station-Id}', '%{Service-Type}', \ '%{Framed-Protocol}', '%{Framed-IP-Address}', '0')" Point 2) I have to limit the user's bandwith so I think about a simple possibility to do that. The best way imho would be a entry in "radreplay" for this user. I added there e.g. framed-ip-address. Is it possible? And if yes: How? Regards Lars - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/devel.html
What ver of radius u running? # radiusd -v radiusd: FreeRADIUS Version 1.0.2, for host , built on May 4 2005 at 22:51:10 Copyright (C) 2000-2003 The FreeRADIUS server project. Andrew Paternoster andrew@gpk.net.au Senior System Engineer GPK Computers Pty. Ltd. A.B.N 72 075 618 012 P.O. 407 Mt Evelyn Melbourne, VIC 3796 Australia Tel: 1300 854 223 Fax: 1300 854 223 ________________________________ -----Original Message----- From: freeradius-devel-bounces+andrew=gpk.net.au@lists.freeradius.org [mailto:freeradius-devel-bounces+andrew=gpk.net.au@lists.freeradius.org] On Behalf Of Lars Sent: Wednesday, 18 March 2009 10:39 PM To: freeradius-devel@lists.freeradius.org Subject: gigawords and bandwith Hi, i'm new here and i need your help in the following 2 points. Point 1: Acct-Input/Output-Gigawords Point 2: Bandwithlimit with PPP and PPPoE My system: debian with kernel 2.6.8-2-386, Roaring Penguin PPPoE Version 3.10, PPP 2.4.4 (not quit sure) and MySQL 4.1.10a. Point 1) After I recognized that the accounting data (acct-input/output-octet) will set to zero if the user downloaded more than 4 GB I added to sql.conf and to table radacct the parameter acct-input/output-gigawords. But It won't be filled with data, it's always zero. The sql statements look like this ({acct_table1} and {acct_table2} are both radacct) accounting_update_query = "UPDATE ${acct_table1} \ SET FramedIPAddress = '%{Framed-IP-Address}', \ AcctSessionTime = '%{Acct-Session-Time}', \ AcctInputOctets = '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ AcctOutputOctets = '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}' \ WHERE AcctSessionId = '%{Acct-Session-Id}' \ AND UserName = '%{SQL-User-Name}' \ AND NASIPAddress= '%{NAS-IP-Address}'" accounting_stop_query = "UPDATE ${acct_table2} \ SET AcctStopTime = '%S', \ AcctSessionTime = '%{Acct-Session-Time}', \ AcctInputOctets = '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ AcctOutputOctets = '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ AcctTerminateCause = '%{Acct-Terminate-Cause}', \ AcctStopDelay = '%{Acct-Delay-Time}', \ ConnectInfo_stop = '%{Connect-Info}' \ WHERE AcctSessionId = '%{Acct-Session-Id}' \ AND UserName = '%{SQL-User-Name}' \ AND NASIPAddress = '%{NAS-IP-Address}'" accounting_stop_query_alt = "INSERT into ${acct_table2} \ (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, \ NASPortId, NASPortType, AcctStartTime, AcctStopTime, AcctSessionTime, \ AcctAuthentic, ConnectInfo_start, ConnectInfo_stop, AcctInputOctets, \ AcctOutputOctets, CalledStationId, CallingStationId, AcctTerminateCause, \ ServiceType, FramedProtocol, FramedIPAddress, AcctStartDelay, AcctStopDelay) \ values('%{Acct-Session-Id}', '%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', \ '%{Realm}', '%{NAS-IP-Address}', '%{NAS-Port}', '%{NAS-Port-Type}', \ DATE_SUB('%S', INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0}) SECOND), \ '%S', '%{Acct-Session-Time}', '%{Acct-Authentic}', '', '%{Connect-Info}', \ '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ '%{Called-Station-Id}', '%{Calling-Station-Id}', '%{Acct-Terminate-Cause}', \ '%{Service-Type}', '%{Framed-Protocol}', '%{Framed-IP-Address}', '0', '%{Acct-Delay-Time}')" accounting_update_query_alt = "INSERT into ${acct_table1} \ (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, \ NASPortId, NASPortType, AcctStartTime, AcctSessionTime, \ AcctAuthentic, ConnectInfo_start, AcctInputOctets, AcctOutputOctets, \ CalledStationId, CallingStationId, ServiceType, FramedProtocol, \ FramedIPAddress, AcctStartDelay) values('%{Acct-Session-Id}', \ '%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', '%{Realm}', \ '%{NAS-IP-Address}', '%{NAS-Port}', '%{NAS-Port-Type}', \ DATE_SUB('%S',INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0}) SECOND), \ '%{Acct-Session-Time}', '%{Acct-Authentic}', '', \ '%{Acct-Input-Gigawords:-0}' << 32 | '%{Acct-Input-Octets:-0}', \ '%{Acct-Output-Gigawords:-0}' << 32 | '%{Acct-Output-Octets:-0}', \ '%{Called-Station-Id}', '%{Calling-Station-Id}', '%{Service-Type}', \ '%{Framed-Protocol}', '%{Framed-IP-Address}', '0')" Point 2) I have to limit the user's bandwith so I think about a simple possibility to do that. The best way imho would be a entry in "radreplay" for this user. I added there e.g. framed-ip-address. Is it possible? And if yes: How? Regards Lars - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/devel.html
Lars <eaglelw@gmx.de> wrote:
What ver of radius u running?
# radiusd -v radiusd: FreeRADIUS Version 1.0.2, for host , built on May 4 2005 at 22:51:10 Copyright (C) 2000-2003 The FreeRADIUS server project.
I have to say it, but is anyone else thinking what I am thinking? :) I bet Arran is plus I'm surprised Alan didn't offer help on how to purchase a new NAS...twas a missed opportunity I feel. Bah, enough rambling. Cheers -- Alexander Clouter .sigmonster says: VICARIOUSLY experience some reason to LIVE!!
Lars <eaglelw@gmx.de> wrote:
What ver of radius u running?
# radiusd -v radiusd: FreeRADIUS Version 1.0.2, for host , built on May 4 2005 at
22:51:10
Copyright (C) 2000-2003 The FreeRADIUS server project.
I have to say it, but is anyone else thinking what I am thinking? :) I bet Arran is plus I'm surprised Alan didn't offer help on how to purchase a new NAS...twas a missed opportunity I feel. Thanks for help :-)
Lars wrote:
i'm new here and i need your help in the following 2 points.
General questions belong on the freeradius-users list, not the developers list.
Point 1) After I recognized that the accounting data (acct-input/output-octet) will set to zero if the user downloaded more than 4 GB I added to sql.conf and to table radacct the parameter acct-input/output-gigawords. But It won't be filled with data, it's always zero.
See the FAQ. If the server isn't logging accounting data, it's because the NAS isn't sending it.
Point 2) I have to limit the user's bandwith so I think about a simple possibility to do that. The best way imho would be a entry in "radreplay" for this user. I added there e.g. framed-ip-address. Is it possible? And if yes: How?
Huh? Adding Framed-IP-Address won't limit bandwidth. See the NAS documentation (pppoe) for instructions on using RADIUS to limit bandwidth. If it's not documented, it's not possible. Alan DeKok.
4 GB I added to sql.conf and to table radacct the parameter acct-input/output-gigawords. But It won't be filled with data, it's always zero.
See the FAQ. If the server isn't logging accounting data, it's because the NAS isn't sending it.
The nas is sending accounting information, but only in acct-input/output-octed not in gigawords, that's my problem.
Point 2) I have to limit the user's bandwith so I think about a simple possibility to do that. The best way imho would be a entry in "radreplay" for this user. I added there e.g. framed-ip-address. Is it possible? And if yes: How?
Huh? Adding Framed-IP-Address won't limit bandwidth. See the NAS documentation (pppoe) for instructions on using RADIUS to limit bandwidth. If it's not documented, it's not possible.
No, i know that framed-ip-address won't limit bandwith, i want to have a parameter to limit bandwith in the same table as "frame-ip-address" (radreplay). Regards lars
Lars wrote:
4 GB I added to sql.conf and to table radacct the parameter acct-input/output-gigawords. But It won't be filled with data, it's always zero.
See the FAQ. If the server isn't logging accounting data, it's because the NAS isn't sending it.
The nas is sending accounting information, but only in acct-input/output-octed not in gigawords, that's my problem.
So... get the NAS to send it. Or buy a NAS that semds it.
See the NAS documentation (pppoe) for instructions on using RADIUS to limit bandwidth. If it's not documented, it's not possible.
No, i know that framed-ip-address won't limit bandwith, i want to have a parameter to limit bandwith in the same table as "frame-ip-address" (radreplay).
See the NAS documentation for instructions on using RADIUS to limit bandwidth. That's what I said before. It's still true. Alan DeKok.
So... get the NAS to send it. Or buy a NAS that semds it.
I hoped that one of you can give me a hint on how.
See the NAS documentation for instructions on using RADIUS to limit bandwidth.
I wrote the version and the kind of NAS before, so I hoped it could be true that one of all the guys here did it before with the same configuration. The documentation of the NAS is not detailed enough to get the needed information! I wrote in freeradius-users also, but i think I can not get the list, but I subscribed to it and send to it without errors - so I ask here again. Regards Lars
participants (4)
-
Alan DeKok -
Alexander Clouter -
Andrew Paternoster -
Lars