freeradius sqlite3 unable to open database file

Antonio Silva asilva at wirelessmundi.com
Fri Mar 31 00:06:31 CEST 2017


Hi,

with sqlite3 is working fine using version 3.0.13, but time to time i 
have to restart it because is unable open sqlite file.
There is no other process using this file and after the restart it works 
fine for a few days more.

Any idea how can i track this done?


LOGs:


Mar 29 09:24:05 H radiusd[3167]: Need 4 more connections to reach 10 spares
Mar 29 09:24:05 H radiusd[3167]: rlm_sql (sql): Opening additional 
connection (15497), 1 of 19 pending slots used
Mar 29 09:24:05 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:24:28 H radiusd[3167]: rlm_sql (sql): Closing connection 
(15491): Hit idle_timeout, was idle for 78 seconds
Mar 29 09:24:28 H radiusd[3167]: rlm_sql (sql): Closing connection 
(15494): Hit idle_timeout, was idle for 74 seconds
Mar 29 09:24:28 H radiusd[3167]: rlm_sql (sql): Closing connection 
(15496): Hit idle_timeout, was idle for 74 seconds
Mar 29 09:24:28 H radiusd[3167]: rlm_sql (sql): Closing connection 
(15490): Hit idle_timeout, was idle for 74 seconds
Mar 29 09:24:29 H radiusd[3167]: Need 7 more connections to reach 10 spares
Mar 29 09:24:29 H radiusd[3167]: rlm_sql (sql): Opening additional 
connection (15498), 1 of 22 pending slots used
Mar 29 09:24:29 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:24:31 H radiusd[3167]: Need 6 more connections to reach 10 spares
Mar 29 09:24:31 H radiusd[3167]: rlm_sql (sql): Opening additional 
connection (15499), 1 of 21 pending slots used
Mar 29 09:24:31 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:19 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:19 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: Need 6 more connections to reach 10 spares
Mar 29 09:25:20 H radiusd[3167]: rlm_sql (sql): Opening additional 
connection (15500), 1 of 20 pending slots used
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Error opening SQLite 
database "radius.db": Code 0x000e (14): unable to open database file
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Error opening SQLite 
database "radius.db": Code 0x000e (14): unable to open database file
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Error opening SQLite 
database "radius.db": Code 0x000e (14): unable to open database file
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Error opening SQLite 
database "radius.db": Code 0x000e (14): unable to open database file
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:20 H radiusd[3167]: rlm_sql_sqlite: Error opening SQLite 
database "radius.db": Code 0x000e (14): unable to open database file
Mar 29 09:25:20 H radiusd[3167]: (14595) sql: ERROR: Hit reconnection limit
Mar 29 09:25:30 H radiusd[3167]: rlm_sql_sqlite: Got SQLite error code 
(5) when closing socket
Mar 29 09:25:30 H radiusd[3167]: rlm_sql_sqlite: Opening SQLite database 
"radius.db"
Mar 29 09:25:30 H radiusd[3167]: rlm_sql_sqlite: Error opening SQLite 
database "radius.db": Code 0x000e (14): unable to open database file
Mar 29 09:25:30 H radiusd[3167]: rlm_sql (sql): Failed to reconnect 
(15495), no free connections are available


Conf:


thread pool {
     start_servers = 5
     max_servers = 25
     min_spare_servers = 3
     max_spare_servers = 10
     max_requests_per_server = 1024
     auto_limit_acct = yes
}

sql {
     driver = "rlm_sql_sqlite"
     sqlite {
             filename = "radius.db"
             busy_timeout = 200
     }
     dialect = "sqlite"
     delete_stale_sessions = yes
     pool {
             start = ${thread[pool].start_servers}
             min = ${thread[pool].min_spare_servers}
             max = ${thread[pool].max_servers}
             spare = ${thread[pool].max_spare_servers}
             uses = 0
             retry_delay = 30
             lifetime = 0
             idle_timeout = 60
     }

}


More information about the Freeradius-Users mailing list