From: Alan T. DeKok Date: Wed, 29 Nov 2023 15:25:48 +0000 (-0500) Subject: more notes on connection starvation X-Git-Tag: release_3_2_4~109 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a69bc4a6b236fd8aa985c5ef246f366ccb70cb41;p=thirdparty%2Ffreeradius-server.git more notes on connection starvation --- diff --git a/raddb/mods-available/sql b/raddb/mods-available/sql index db58421ede..68ac4da753 100644 --- a/raddb/mods-available/sql +++ b/raddb/mods-available/sql @@ -291,6 +291,23 @@ sql { # # Setting 'max' to MORE than the number of threads means # that there are more connections than necessary. + # + # The setting here should be lower than the maximum + # number of connections allowed by the database. + # + # i.e. There is no point in telling FreeRADIUS to use + # 64 connections, while the database is limited to 32 + # connections. That configuration will cause the + # server to be "starved" of connections, and it will + # block during normal operations, even when the + # database is largely idle. + # + # At the same time, if the database is slow, there is + # no point in increasing "max". More connections + # will just cause the database to run more slowly. + # The correct fix for a slow database is to fix it, so + # that it responds to FreeRADIUS quickly. + # max = ${thread[pool].max_servers} # Spare connections to be left idle