Freeradius 3.0.7 and multiple buffered-sql servers - detail file issues
Alan DeKok
aland at deployingradius.com
Tue Apr 21 15:38:56 CEST 2015
On Apr 21, 2015, at 2:35 AM, Marcin <marcin at nicram.net> wrote:
> So, which is better solution for performance: keep accounting data in
> details file, then read it and write to db with buffered-sql or write
> accounting to database directly?
Typically writing to a database directly is lower latency than writing to the detail file and then to the DB.
In v3, the pool configuration helps a lot. Set a "max" number of connections the DB can handle, and fail-over to the detail file. In normal operation, everything goes directly to the DB. If you get a huge spike of traffic, the detail file fills up. And then drains slowly when the spike goes away.
> In configuration file buffered-sql we can read:
> #v+
> The server can read accounting packets from the detail file much more
> quickly than those packets an be written to a database. If the database is
> overloaded, then bad things can happen.
Yes, which means you can read 100K packets/s from the detail file, and only write 2K packets/s to the DB. This shouldn't be surprising.
Alan DeKok.
More information about the Freeradius-Users
mailing list