On Fri, Mar 26, 2004 at 06:38:26PM +0100, Andreas M. wrote:
> Hi,
> we are using Freeradius together with mysql. Now we ativated the interim accounting
> on an Cisco LNS.
> In the "accounting_update_query" is nothing regarding session time and acctOctets in
> both directions.
> Is there any reason for this?
Nothing particular. You're free to change it locally.
> In the "Interim" specification the accounting update should be similar to a stop
> record, without termination_cause and stop time.
Here's what I've got:
accounting_update_query = "UPDATE ${acct_table1} SET FramedIPAddress =
'%{Framed-IP-Address}', AcctSessionTime = '%{Acct-Session-Time}', AcctInputOctets =
('%{Acct-Input-Octets}' + ('%{Acct-Input-Gigawords:-0}' * POW(2,32))),
AcctOutputOctets = ('%{Acct-Output-Octets}' + ('%{Acct-Output-Gigawords:-0}' *
POW(2,32))) WHERE AcctSessionId = '%{Acct-Session-Id}' AND UserName =
'%{SQL-User-Name}' AND NASIPAddress= '%{NAS-IP-Address}' AND AcctStopTime = 0"
Of course, I've munged the octet count fields to take more than a 32-bit
number. :-)
--
Paul "TBBle" Hampson, on an alternate email client
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html