[sqlippool]IP address could not be allocated as no pool exists with that name
Rod Elias
falajhou at gmail.com
Tue Oct 27 18:48:23 CET 2015
Hello list!
Could someone please help me with a problem regarding freeradius
sqlippool module?
I'm migrating to FreeRADIUS Version 2.1.10 with MySQL 5.1.73-1 running
on a Debian GNU/Linux 6
The content of my radcheck table is something like:
mysql> select * from radcheck where UserName = 'lucasmenezes';
+-------+-------------------------+--------------------+----------------+----+
| id | UserName | Attribute | Value | op |
+-------+-------------------------+--------------------+----------------+----+
| 15643 | lucasmenezes | Cleartext-Password | 12110 | := |
| 22342 | lucasmenezes | Pool-Name | PONTALNORTE_02 | := |
+-------+-------------------------+--------------------+----------------+----+
2 rows in set (0.00 sec)
When the mentioned user tries to authenticate, I get the error message
"IP address could not be allocated as no pool exists with that name".
The user receives Login OK, but radius releases IP 0.0.0.0 to her/him.
Here is an **example** of my radippool table:
mysql> select * from radcheck where UserName = 'lucasmenezes';
+-------+----------------+-----------------+--------------+-----------------+-------------------+---------------------+-------------------------+-------------------+
| id | pool_name | FramedIPAddress | NASIPAddress |
CalledStationId | CallingStationID | expiry_time | username
| pool_key |
+-------+----------------+-----------------+--------------+-----------------+-------------------+---------------------+-------------------------+-------------------+
| 64171 | PONTALNORTE_02 | 187.44.69.244 | 187.44.64.58 |
| 00:0C:43:B4:1B:81 | 2015-10-27 16:00:10 | lucasmenezes
| 00:0C:43:B4:1B:81 |
+-------+----------------+-----------------+--------------+-----------------+-------------------+---------------------+-------------------------+-------------------+
1 row in set (0.00 sec)
For some reason, I noticed the %{control:Pool-Name} section in the SQL
query isn't being resolved and, because that, SQL query doesn't return
any results.
Please let me post bellow the output of freeradius -X regarding that situation:
Login OK: [lucasmenezes] (from client MK_Pontal port 15728946 cli
00:0C:43:B4:1B:81)
# Executing section post-auth from file /etc/freeradius/sites-enabled/default
+- entering group post-auth {...}
rlm_sql (sql): Reserving sql socket id: 110
[sqlippool] expand: %{User-Name} -> lucasmenezes
[sqlippool] sql_set_user escaped user --> 'lucasmenezes'
[sqlippool] expand: START TRANSACTION -> START TRANSACTION
[sqlippool] expand: UPDATE radippool SET nasipaddress = '',
pool_key = 0, callingstationid = '', username = '', expiry_time =
NULL WHERE expiry_time <= NOW() - INTERVAL 1 SECOND AND
nasipaddress = '%{Nas-IP-Address}' -> UPDATE radippool SET
nasipaddress = '', pool_key = 0, callingstationid = '', username =
'', expiry_time = NULL WHERE expiry_time <= NOW() - INTERVAL 1
SECOND AND nasipaddress = '187.44.64.58'
[sqlippool] expand: SELECT framedipaddress FROM radippool WHERE
pool_name = '%{control:Pool-Name}' AND (expiry_time < NOW() OR
expiry_time IS NULL) ORDER BY (username <> '%{User-Name}'),
(callingstationid <> '%{Calling-Station-Id}'), expiry_time LIMIT 1
FOR UPDATE -> SELECT framedipaddress FROM radippool WHERE pool_name =
'' AND (expiry_time < NOW() OR expiry_time IS NULL) ORDER BY
(username <> 'lucasmenezes'), (callingstationid <>
'00:0C:43:B4:1B:81'), expiry_time LIMIT 1 FOR UPDATE
[sqlippool] SQL query did not return any results
[sqlippool] expand: COMMIT -> COMMIT
[sqlippool] expand: SELECT id FROM radippool WHERE
pool_name='%{control:Pool-Name}' LIMIT 1 -> SELECT id FROM radippool
WHERE pool_name='' LIMIT 1
[sqlippool] SQL query did not return any results
rlm_sql (sql): Released sql socket id: 110
[sqlippool] IP address could not be allocated as no pool exists with that name.
++[sqlippool] returns noop
++[exec] returns noop
Any help please? What am I missing?
Thanks a lot in advanced.
Best regards,
[]'s
--
More information about the Freeradius-Users
mailing list