SQL and Proxy acct in a virtual server
Frank Bollet
frankbollet at yahoo.com
Tue Oct 26 12:52:19 CEST 2010
Hi all,
I'm using Freeradius 1.x for a few years now and I'd like to switch to
Freeradius 2.1.10.
I have 11 realms:
- 7 are managed by this server, using an SQL database
- 4 are proxied to different partners, but accountings are saved in the SQL
database.
Virtual servers seems to be great for this purpose, but I have a few issues with
the configuration.
I defined realms, home server pools and home server.
For locally managed realms, I defined a virtual server for each realm (in
sites-available/) and the home server refers to that virtual server. Here is an
example for the realm "@foo":
###
server vs_foo {
authorize {
[...]
sql_foo
[...]
}
[...]
}home_server hs_vs_foo {
virtual_server = vs_foo
}
home_server_pool hsp_vs_foo {
home_server = hs_vs_foo
}
realm foo {
pool = hsp_vs_foo
}
###
It's working like I want to for the locally managed realms, but how could I
define different virtual servers for the proxied realms ?
I could just define the server to proxy the request to in proxy.conf and do
accounting in the default virtual server, just like I was doing with Freeradius
1, but I'd like to define virtual servers in order to separate each realms in
virtual servers.
If I define home servers and a virtual server in a home server pool, the virtual
server is only used for pre/post proxy. "accounting {}" is used from
sites-enabled/default. How could I define a specific accounting for a given
realm ?
Here is what I'm doing for proxied realms:
###
server vs_bar {
accounting {
sql_bar
}
}
home_server hs_bar {
type = auth+acct
ipaddr = [...]
[...]
}
home_server_pool hsp_bar {
type = fail-over
home_server = hs_bar
virtual_server = vs_bar
}
realm bar {
pool = hsp_bar
nostrip
}
###
The request is proxied but the accounting section is taken from default and not
from vs_bar. What am I doing wrong?
Thank you,
Frank.
More information about the Freeradius-Users
mailing list