Hi! I have a question about failover configuration.<br /><br />I have freeradius + sqlippool module for ip-assigning. I have 2 databases for redundancy (described in sql1 and sql2). <br /><br />my file from enabled-server:<br /><br />server allauth {<br /> listen {<br /> type = auth<br /> ipaddr = *<br /> port = 1812<br /> }<br /> authorize {<br /> auth_log<br /> update control {<br /> Pool-Name = 'main_pool'<br /> }<br /> redundant {<br /> # we need this only to get new Pool-name, if user exist in our defined group.<br /> sql1 <br /> sql2<br /> }<br /> update control {<br /> # any user must be accepted.<br /> Auth-Type = 'Accept'<br /> }<br /> }<br /> post-auth {<br /> redundant {<br /> sqlippool1 # this module use sql1 for assigning<br /> sqlippool2 # this module use sql2 for assigning, if first will fails.<br /> main_pool<br /> }<br /> reply_log<br /> }<br />}<br /><br />I've run the freeradius, but when I turned off my first database (sql1), my redundancy in post-auth return incorrect code:, sqlippool1 returns "noop", neither "fail".<br />May be I've selected the wrong way to solve my task? Any comments are welcome... How can I switch ip-assigning on sqlippool2, when sql1 (used by sqlippool1) doesn't work?<br /><br />some information from log:<br /><br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql (sql1): Failed to connect DB handle #1<br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql (sql1): reconnect failed, database down?<br />Wed Feb 3 15:36:29 2010 : Error: sqlippool_command: database query error in: 'COMMIT'<br />Wed Feb 3 15:36:29 2010 : Info: [sqlippool1] expand: SELECT id FROM radippool WHERE pool_name='%{control:Pool-Name}' LIMIT 1 -> SELECT id FROM radippool WHERE pool_name='main_pool' LIMIT 1<br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql_mysql: Socket not connected<br />Wed Feb 3 15:36:29 2010 : Debug: rlm_sql (sql1): Attempting to connect rlm_sql_mysql #1<br />Wed Feb 3 15:36:29 2010 : Info: rlm_sql_mysql: Starting connect to MySQL server for #1<br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql_mysql: Couldn't connect socket to MySQL server user@ip:dbname<br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql_mysql: Mysql error 'Lost connection to MySQL server at 'reading initial communication packet', system error: 0'<br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql (sql1): Failed to connect DB handle #1<br />Wed Feb 3 15:36:29 2010 : Error: rlm_sql (sql1): reconnect failed, database down?<br />Wed Feb 3 15:36:29 2010 : Error: sqlippool_query1: database query error<br />Wed Feb 3 15:36:29 2010 : Debug: rlm_sql (sql1): Released sql socket id: 1<br />Wed Feb 3 15:36:29 2010 : Info: [sqlippool1] IP address could not be allocated as no pool exists with that name.<br />Wed Feb 3 15:36:29 2010 : Info: +++[sqlippool1] returns noop<br />Wed Feb 3 15:36:29 2010 : Info: ++- policy redundant returns noop
<!-- -->