Cleanup Stale Sessions - needed?

Fajar A. Nugraha list at fajar.net
Tue Jun 21 03:53:11 CEST 2011


On Tue, Jun 21, 2011 at 6:17 AM, Paolo Di Francesco
<paolo.difrancesco at level7.it> wrote:
> Hi Gary
>
> I did the same in many other situations, and not always I got the
> expected result.
>
> In some circumstances it was working, in others it was like the "press
> here to collapse the world" just with the stickers "press me honey" on
> top of it.
>
> Just wondering if somebody can point me to the right link, script or
> whatever to solve this problem...

That depends on what you use to track simultaneous use. What's on
"session" section of sites-available/default? Is it radutmp? sql?

If it's radutmp, try "man radzap" and "man radwho".

If it's sql, you should be able to just update your radacct table.
What to update might be different in different implementation. IIRC
the default schema marks ongoing session with a NULL on acctstoptime,
so you could probably just update it to current time.  My
implementation is somewhat different, in that it stores
Acct-Status-Type and use AcctStopTime to record the time the
accounting packet was received. In any case, look at your radacct
table and accounting queries (e.g. sql/mysql/dialup.conf), and you
should be able to find out what to change.

-- 
Fajar



More information about the Freeradius-Users mailing list