On Thu, 2018-06-21 at 12:38 +0200, Javier Escalante wrote:
(0) sql: SQL-User-Name set to 'test' rlm_sql (sql): Reserved connection (0) (0) sql: EXPAND SELECT id, username, attribute, value, op FROM radcheck WHERE username = '%{SQL-User-Name}' ORDER BY id (0) sql: --> SELECT id, username, attribute, value, op FROM radcheck WHERE username = 'test' ORDER BY id
So when you manually run the SQL query SELECT id, username, attribute, value, op FROM radcheck WHERE username = 'test' ORDER BY id does it come back with the right data?
(0) sql: Executing select query: SELECT id, username, attribute, value, op FROM radcheck WHERE username = 'test' ORDER BY id (0) sql: EXPAND SELECT groupname FROM radusergroup WHERE username = '%{SQL-User-Name}' ORDER BY priority (0) sql: --> SELECT groupname FROM radusergroup WHERE username = 'test' ORDER BY priority (0) sql: Executing select query: SELECT groupname FROM radusergroup WHERE username = 'test' ORDER BY priority (0) sql: User not found in any groups
It's doing group checks, and there's nothing in the radusergroup table. See https://wiki.freeradius.org/modules/Rlm_sql#sql-schema-and-usage an d look at the comments near the "read_groups" SQL option.
rlm_sql (sql): Released connection (0) Need 5 more connections to reach 10 spares rlm_sql (sql): Opening additional connection (5), 1 of 27 pending slots used (0) [sql] = notfound
-- Matthew