Hi list,
I need to setup a radius-only ser. Is it possible to make use of the check_to and check_from functions from the uri.so module without loading a mysql or other database module?
Thank you,
regards, Martin
Hi Martin,
as it is on cvs, the DB connection is mandatory for the uri module - it is not a requirement, but a design choice.
I attached a small patch (for 0.8.14) which will allow you to set the module parameter "db_url" to an empty value/string and to disable the DB support. Use: modparam("uri", "db_url", "" )
NOTE that the functions "does_uri_exist()" and "is_user()" (in combination with "use_uri_table" parameter) will not work in this case. Please let me know if it works for you.
Best regards, Marian Dumitru
Martin Koenig wrote:
Hi list,
I need to setup a radius-only ser. Is it possible to make use of the check_to and check_from functions from the uri.so module without loading a mysql or other database module?
Thank you,
regards, Martin
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
Hi Marian,
The patch itself looks fine, but it is not working so far.
The debug output reads: 0(18168) DEBUG: init_mod: uri 0(18168) uri - initializing 0(18168) find_export: <db_use_table> not found 0(18168) uri:mod_init(): No database module found 0(18168) init_mod(): Error while initializing module uri ERROR: error while initializing modules
Ser.cfg has the following uri.so-related lines: loadmodule "/usr/local/lib/ser/modules/uri.so" modparam("uri", "db_url", "") modparam("uri", "use_uri_table", 0)
Do i still need to load the mysql.so module, although no connection will be made?
Thanks alot,
Best regards, Martin
-----Original Message----- From: Marian Dumitru [mailto:marian.dumitru@voice-sistem.ro] Sent: Wednesday, October 13, 2004 5:50 PM To: Martin Koenig Cc: serusers@lists.iptel.org Subject: Re: [Serusers] Uri module without Database
Hi Martin,
as it is on cvs, the DB connection is mandatory for the uri module - it is not a requirement, but a design choice.
I attached a small patch (for 0.8.14) which will allow you to set the module parameter "db_url" to an empty value/string and to disable the DB support. Use: modparam("uri", "db_url", "" )
NOTE that the functions "does_uri_exist()" and "is_user()" (in combination with "use_uri_table" parameter) will not work in this case. Please let me know if it works for you.
Best regards, Marian Dumitru
Martin Koenig wrote:
Hi list,
I need to setup a radius-only ser. Is it possible to make use of the check_to and check_from functions from the uri.so module
without loading a
mysql or other database module?
Thank you,
regards, Martin
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
-- Voice Sistem http://www.voice-sistem.ro
Hello Marian,
I worked a little bit on the patch, and the code in uri_mod.c needs to look like this:
if (strlen(db_url)==0) { if (use_uri_table) { LOG(L_ERR, "uri:mod_init(): database disabled, " ""use_uri_table" set -> conflict\n"); return -1; } DBG("uri:mod_init(): not binding to database module\n"); db_url = 0; } else { if (bind_dbmod()) { LOG(L_ERR, "uri:mod_init(): No database module found\n"); return -1; } }
It seems to work with this. There may not be a bind_dbmod()-call, or else stuff will go wrong.
Maybe you can review this and put it in your patch.
Thanks again,
regards, Martin
-----Original Message----- From: Marian Dumitru [mailto:marian.dumitru@voice-sistem.ro] Sent: Wednesday, October 13, 2004 5:50 PM To: Martin Koenig Cc: serusers@lists.iptel.org Subject: Re: [Serusers] Uri module without Database
Hi Martin,
as it is on cvs, the DB connection is mandatory for the uri module - it is not a requirement, but a design choice.
I attached a small patch (for 0.8.14) which will allow you to set the module parameter "db_url" to an empty value/string and to disable the DB support. Use: modparam("uri", "db_url", "" )
NOTE that the functions "does_uri_exist()" and "is_user()" (in combination with "use_uri_table" parameter) will not work in this case. Please let me know if it works for you.
Best regards, Marian Dumitru
Martin Koenig wrote:
Hi list,
I need to setup a radius-only ser. Is it possible to make use of the check_to and check_from functions from the uri.so module
without loading a
mysql or other database module?
Thank you,
regards, Martin
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
-- Voice Sistem http://www.voice-sistem.ro
Hi Juha,
That is correct, but to my knowledge the check_to and check_from functions are presented in the uridb module, thus the situation did not change really.
I need checking of to and from against digest credentials as presented in the readme of the (old unsplit) uri module. This is not possible at the moment without a database module. That doesn't make sense for a radius ser setup ;)
I like Marian's approach though. Check hist posting to the list.
Best regards, Martin
-----Original Message----- From: Juha Heinanen [mailto:jh@tutpro.com] Sent: Wednesday, October 13, 2004 6:36 PM To: Martin Koenig Cc: serusers@lists.iptel.org Subject: [Serusers] Uri module without Database
Martin Koenig writes:
I need to setup a radius-only ser. Is it possible to make
use of the
check_to and check_from functions from the uri.so module
without loading a
mysql or other database module?
uri module has been split in unstable version.
-- juha