Virtual Server with Multiple Databases

Kelvin Chiang chiang_kelvin at hotmail.com
Thu Jan 22 07:52:36 CET 2009


Hi,

I am currently using version 2.1.3-1. I was trying to create virtual servers accessing to different mysql databases. From some of the historical threads, I understood that the followings steps are needed:

1. Create an entry in /etc/raddb/dictionary. I had the line as:

ATTRIBUTE My-DB 3000 String

2. I edit the sql.conf with the following:

radius_db = %{control:My-DB}

3. In the virtual server section, I added the following at the top of the authorize and preacct sections:

update control {
    My-DB = "my_radiusdb_name"
}


With the above 3 changes, I run radiusd -X and I get the below errors. Can anyone help to identify what went wrong?

rad_recv: Access-Request packet from host 192.168.188.1 port 57018, id=206, length=138
    NAS-IP-Address = 208.75.51.88
    NAS-Identifier = "vpn.skywalk.net"
    User-Name = "kelvincrypt"
    User-Password = "test"
    Service-Type = Login-User
    NAS-Port-Type = Ethernet
    NAS-Port = 3
    Framed-IP-Address = 192.168.188.200
    Called-Station-Id = "00:0d:48:36:2f:ff"
    Calling-Station-Id = "00:17:08:3e:a2:21"
server radius_test {
+- entering group authorize {...}
++[control] returns notfound
++[preprocess] returns ok
[auth_log]     expand: /var/log/radius/radacct/%{Client-IP-Address}/auth-detail-%Y%m%d -> /var/log/radius/radacct/192.168.188.1/auth-detail-20090122
[auth_log] /var/log/radius/radacct/%{Client-IP-Address}/auth-detail-%Y%m%d expands to /var/log/radius/radacct/192.168.188.1/auth-detail-20090122
[auth_log]     expand: %t -> Thu Jan 22 14:05:35 2009
++[auth_log] returns ok
++[chap] returns noop
[suffix] No '@' in User-Name = "kelvincrypt", looking up realm NULL
[suffix] No such realm "NULL"
++[suffix] returns noop
[eap] No EAP-Message, not doing EAP
++[eap] returns noop
[radius_test_sql]     expand: %{User-Name} -> kelvincrypt
[radius_test_sql] sql_set_user escaped user --> 'kelvincrypt'
rlm_sql (radius_test_sql): Ignoring unconnected handle 4..
rlm_sql (radius_test_sql): Ignoring unconnected handle 3..
rlm_sql (radius_test_sql): Ignoring unconnected handle 2..
rlm_sql (radius_test_sql): Ignoring unconnected handle 1..
rlm_sql (radius_test_sql): Ignoring unconnected handle 0..
rlm_sql (radius_test_sql): There are no DB handles to use! skipped 5, tried to connect 0
++[radius_test_sql] returns fail
} # server radius_test
Using Post-Auth-Type Reject
+- entering group Reject {...}
++[reply] returns noop
Delaying reject of request 0 for 1 seconds
Going to the next request
Waking up in 0.9 seconds.
Sending delayed reject for request 0
Sending Access-Reject of id 206 to 192.168.188.1 port 57018
    Reply-Message = "Authentication failed."
Waking up in 4.9 seconds.


_________________________________________________________________
See all the ways you can stay connected to friends and family
http://www.microsoft.com/windows/windowslive/default.aspx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20090122/ba17d088/attachment.html>


More information about the Freeradius-Users mailing list