#
#
# Load-balancing and failover between home servers is handled via
-# a "server_pool" section.
+# a "home_server_pool" section.
#
# Finally, The "realm" section defines the realm, some options, and
# indicates which server pool should be used for the realm.
# the same 10 realms, you would need 50 "realm" entries.
#
# In version 2.0, you would need 5 "home_server" sections,
-# 10 'realm" sections, and one "server_pool" section to tie the
+# 10 'realm" sections, and one "home_server_pool" section to tie the
# two together.
#
-server_pool my_auth_failover {
+home_server_pool my_auth_failover {
#
# The type of this pool controls how home servers are chosen.
#
# Realms point to pools of home servers.
#
# For authentication, the "auth_pool" configuration item
- # should point to a "server_pool" that was previously
+ # should point to a "home_server_pool" that was previously
# defined. All of the home servers in the "auth_pool" must
# be of type "auth".
#
# For accounting, the "acct_pool" configuration item
- # should point to a "server_pool" that was previously
+ # should point to a "home_server_pool" that was previously
# defined. All of the home servers in the "acct_pool" must
# be of type "acct".
#
- # If you have a "server_pool" where all of the home servers
+ # If you have a "home_server_pool" where all of the home servers
# are of type "auth+acct", you can just use the "pool"
# configuration item, instead of specifying both "auth_pool"
# and "acct_pool".
int num_home_servers;
name2 = cf_section_name1(cs);
- if (!name2 || (strcasecmp(name2, "server_pool") != 0)) {
+ if (!name2 || ((strcasecmp(name2, "server_pool") != 0) &&
+ (strcasecmp(name2, "home_server_pool") != 0))) {
cf_log_err(cf_sectiontoitem(cs),
- "Section is not a server_pool.");
+ "Section is not a home_server_pool.");
return 0;
}
num_home_servers);
pool->cs = cs;
- if (do_print) DEBUG2(" server_pool %s {", name2);
+ if (do_print) DEBUG2(" home_server_pool %s {", name2);
cp = cf_pair_find(cs, "type");
if (cp) {
CONF_SECTION *pool_cs;
pool_cs = cf_section_sub_find_name2(rc->cs,
- "server_pool",
+ "home_server_pool",
name);
if (!pool_cs) {
- cf_log_err(cf_sectiontoitem(cs), "Failed to find server_pool \"%s\"", name);
+ pool_cs = cf_section_sub_find_name2(rc->cs,
+ "server_pool",
+ name);
+ }
+ if (!pool_cs) {
+ cf_log_err(cf_sectiontoitem(cs), "Failed to find home_server_pool \"%s\"", name);
return 0;
}
}
if (pool->server_type != server_type) {
- cf_log_err(cf_sectiontoitem(cs), "Incompatible server_pool \"%s\" (mixed auth_pool / acct_pool)", name);
+ cf_log_err(cf_sectiontoitem(cs), "Incompatible home_server_pool \"%s\" (mixed auth_pool / acct_pool)", name);
return 0;
}