ippool configuration causes 3.x server to fail to start
There is a problem in raddb/mods-available/ippool, looks like it wasn't updated correctly for 3.x. It contains the following lines:
# session-db: # The main db file used to allocate addresses. session_db = ${db_dir}/db.ippool
But this causes the following start up error:
/etc/raddb/mods-enabled/ippool[28]: Configuration item 'filename' must have a value } /etc/raddb/mods-enabled/ippool[28]: Invalid configuration for module "main_pool"
It's because of these lines in rlm_ippool.c
{ "session-db", PW_TYPE_FILE_OUTPUT | PW_TYPE_DEPRECATED, offsetof(rlm_ippool_t,filename), NULL, NULL }, { "filename", PW_TYPE_FILE_OUTPUT | PW_TYPE_REQUIRED, offsetof(rlm_ippool_t,filename), NULL, NULL },
Both session-db and filename are mapped to the inst filename attribute but filename is required. Also the attribute name in readdb/mods-available is session_db which doesn't even exist (it's session-db, note hyphen vs. underscore). The raddb/mods-available/ippool needs to have both session-db and session_db changed to filename. I didn't bother producing a patch because the necessary edit is trivial. -- John
but filename is required. Also the attribute name in readdb/mods-available is session_db which doesn't even exist (it's session-db, note hyphen vs. underscore).
The raddb/mods-available/ippool needs to have both session-db and session_db changed to filename.
I didn't bother producing a patch because the necessary edit is trivial.
Done. Thanks for reporting the issue. Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS Development Team FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
On 01/17/2014 11:29 AM, Arran Cudbard-Bell wrote:
but filename is required. Also the attribute name in readdb/mods-available is session_db which doesn't even exist (it's session-db, note hyphen vs. underscore).
The raddb/mods-available/ippool needs to have both session-db and session_db changed to filename.
I didn't bother producing a patch because the necessary edit is trivial.
Done. Thanks for reporting the issue.
Thanks Arran. But just noticed in the commit you missed updating session-db in the comment lines above the filename attribute. That makes it confusing, the comment should use the same name as the attribute. However, it might be worth including in the comment filename used to be called session-db just to help folks during migration. -- John
On 17 Jan 2014, at 16:45, John Dennis <jdennis@redhat.com> wrote:
On 01/17/2014 11:29 AM, Arran Cudbard-Bell wrote:
but filename is required. Also the attribute name in readdb/mods-available is session_db which doesn't even exist (it's session-db, note hyphen vs. underscore).
The raddb/mods-available/ippool needs to have both session-db and session_db changed to filename.
I didn't bother producing a patch because the necessary edit is trivial.
Done. Thanks for reporting the issue.
Thanks Arran. But just noticed in the commit you missed updating session-db in the comment lines above the filename attribute. That makes it confusing, the comment should use the same name as the attribute.
Done.
However, it might be worth including in the comment filename used to be called session-db just to help folks during migration.
That was why I left it in there, it wasn't missed, but I guess users can probably figure out what it's used for by the fact the default value is '${db_dir}/db.ippool'. Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS Development Team FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
participants (2)
-
Arran Cudbard-Bell -
John Dennis