noresetcounter + NULL radacct records (First Connection)
tnt at kalik.net
Tue Sep 8 13:41:41 CEST 2009
> On occasions sqlcounter does not seem to work correctly, especially for
> User that have no radacct details.
> After doing some digging, I've identified the issue only to happen on the
> first ever connect of the user in a new account.
> As you will see from the sql below, if no integer is returned (NULL), then
> Max-All-Sessions and the correct setting of is ignored and
> is skipped.
> How can I address the NULL response for newly created accounts?
> rlm_sqlcounter: Entering module authorize code
> sqlcounter_expand: 'SELECT SUM(AcctSessionTime) FROM radacct WHERE
Alter the counter query:
SELECT IFNULL(SUM(AcctSessionTime),0) FROM radacct WHERE
Does postgre have the same problem (no session limit is returned for the
counter if there are no radacct records)?
Kalik Informatika ISP
More information about the Freeradius-Users