Problem with freeradius 1.1.3 and MySQL reserving sql socket

Raúl Rodríguez raul2r2 at gmail.com
Thu Jan 25 10:04:42 CET 2007


Hi all!
   I'm trying to set-up a freeradius 1.1.3 using MySQL 5.0.22 as
Database Backend... although i have a very annoying problem that i don't
know how to solve. 
   When i launch the service with -X option to see debug, it seems that
everything goes well, although when i try to submit some request to the
server (Auth, access...) it fails with an sql query error without doing
any query (i can confirm this beacuse i was sniffing mysql traffic in
the server). The problem seems to come when the server try to reserve
one sql socket... but there is no error, inmediately it response with an
sql query error... here is the log:

rlm_sql (sql): starting 22
rlm_sql (sql): Attempting to connect rlm_sql_mysql #22
rlm_sql_mysql: Starting connect to MySQL server for #22
rlm_sql (sql): Connected new DB handle, #22
rlm_sql (sql): starting 23
rlm_sql (sql): Attempting to connect rlm_sql_mysql #23
rlm_sql_mysql: Starting connect to MySQL server for #23
rlm_sql (sql): Connected new DB handle, #23
rlm_sql (sql): starting 24
rlm_sql (sql): Attempting to connect rlm_sql_mysql #24
rlm_sql_mysql: Starting connect to MySQL server for #24
rlm_sql (sql): Connected new DB handle, #24
Module: Instantiated sql (sql) 
Module: Loaded Acct-Unique-Session-Id 
 acct_unique: key = "User-Name, Acct-Session-Id, NAS-IP-Address,
Client-IP-Address, NAS-Port"
Module: Instantiated acct_unique (acct_unique) 
Module: Loaded detail 
 detail: detailfile =
"/usr/local/var/log/radius/radacct/%{Client-IP-Address}/detail-%Y%m%d"
 detail: detailperm = 384
 detail: dirperm = 493
 detail: locking = no
Module: Instantiated detail (detail) 
Module: Loaded radutmp 
 radutmp: filename = "/usr/local/var/log/radius/radutmp"
 radutmp: username = "%{User-Name}"
 radutmp: case_sensitive = yes
 radutmp: check_with_nas = yes
 radutmp: perm = 384
 radutmp: callerid = yes
Module: Instantiated radutmp (radutmp) 
Listening on authentication *:1812
Listening on accounting *:1813
Ready to process requests.
rad_recv: Access-Request packet from host 192.168.0.100:9695, id=38,
length=43
        User-Name = "101"
        User-Password = "1234"
  Processing the authorize section of radiusd.conf
modcall: entering group authorize for request 0
  modcall[authorize]: module "preprocess" returns ok for request 0
  modcall[authorize]: module "chap" returns noop for request 0
  modcall[authorize]: module "digest" returns noop for request 0
    rlm_realm: No '@' in User-Name = "101", looking up realm NULL
    rlm_realm: No such realm "NULL"
  modcall[authorize]: module "suffix" returns noop for request 0
  rlm_eap: No EAP-Message, not doing EAP
  modcall[authorize]: module "eap" returns noop for request 0
    users: Matched entry DEFAULT at line 152
  modcall[authorize]: module "files" returns ok for request 0
radius_xlat:  ''
-------------- ERROR -------------------------------------
rlm_sql (sql): Reserving sql socket id: 24
rlm_sql (sql): SQL query error; rejecting user
rlm_sql (sql): Released sql socket id: 24
----------------------------------------------------------
  modcall[authorize]: module "sql" returns fail for request 0
modcall: leaving group authorize (returns fail) for request 0
Finished request 0
...

Thank you in advance.
Raúl.






More information about the Freeradius-Users mailing list