Hello ! I use FreeRADIUS and PostgreSQL for productional VoIP billing. I had found that if SQL server not available during FreeRADIUS startup:
Sun Apr 23 10:08:22 2006 : Info: rlm_sql (pgsql-voip): Driver rlm_sql_postgresql (module rlm_sql_postgresql) loaded and linked Sun Apr 23 10:08:22 2006 : Info: rlm_sql (pgsql-voip): Attempting to connect to voipflik@10.9.9.2:/isbs Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): starting 0 Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): Attempting to connect rlm_sql_postgresql #0 Sun Apr 23 10:08:22 2006 : Error: rlm_sql_postgresql: Couldn't connect socket to PostgreSQL server voipflik@10.9.9.2:isbs Sun Apr 23 10:08:22 2006 : Error: rlm_sql_postgresql: Postgresql error 'could not connect to server: Connection refused ?Is the server running on host "10.9.9 Sun Apr 23 10:08:22 2006 : Error: rlm_sql (pgsql-voip): Failed to connect DB handle #0 Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): starting 1 Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): starting 2 Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): starting 3 Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): starting 4 Sun Apr 23 10:08:22 2006 : Debug: rlm_sql (pgsql-voip): Failed to connect to any SQL server. Sun Apr 23 10:08:22 2006 : Debug: Module: Instantiated sql (pgsql-voip)
then it will not available all the time until we reload FreeRADIUS daemon - it not ever try to reconnect:
Sun Apr 23 10:17:51 2006 : Debug: radius_xlat: 'INSERT into radoriginate (RadiusServerName, UserName, NASIPAddress, AcctStartTime, AcctStopTime, Cal Sun Apr 23 10:17:51 2006 : Debug: rlm_sql (pgsql-voip): Ignoring unconnected handle 4.. Sun Apr 23 10:17:51 2006 : Debug: rlm_sql (pgsql-voip): Ignoring unconnected handle 3.. Sun Apr 23 10:17:51 2006 : Debug: rlm_sql (pgsql-voip): Ignoring unconnected handle 2.. Sun Apr 23 10:17:51 2006 : Debug: rlm_sql (pgsql-voip): Ignoring unconnected handle 1.. Sun Apr 23 10:17:51 2006 : Debug: rlm_sql (pgsql-voip): Ignoring unconnected handle 0.. Sun Apr 23 10:17:51 2006 : Info: rlm_sql (pgsql-voip): There are no DB handles to use! skipped 5, tried to connect 0
Why FreeRADIUS do not try to reconnect during sql command must be proceeded ? Is it possible to fix via configuration parameter or its hard-coded bug ? P.S. I had maid perl-script to recover radius cdrs into DB from standard FreeRADIUS detail-* files. If any interesting in it, I'll public it on the web. Thanks a lot Ruslan A Dautkhanov