Hi,
yes, that's right. OpenSER 1.0.1 dispatcher module does not contain the function/parameter you want to use. See: http://openser.org/docs/modules/1.0.x/dispatcher.html You need to use the 1.1.0 version: http://openser.org/docs/modules/1.1.x/dispatcher.html
regards, bogdan
Peter Childs wrote:
I believe that the failover in the dispatcher was only introduced in the OpenSER 1.1 (not 1.0.1).
On Mon, 2006-07-10 at 19:06 -0500, Jose Gil Navarrete wrote:
Hi, somebody can help me?? I am trying to set up OpenSer 1.0.1 like dispatcher to loadbalance and failover but when I use ds_next_dst() for failover I obtain the next error: 0(19024) parse error (128,25-26): unknown command, missing loadmodule?
ds_select_dst("2","0"); sl_send_reply("100","Trying"); forward(uri:host, uri:port); t_on_failure("1"); if (!t_relay()) { sl_reply_error(); return; };
Wouldn't you do the following (OpenSER will do 100 for you... and you don't need to forward() and t_relay()...
ds_select_dst("2", "0"); t_on_failure("1"); if( !t_relay()) { sl_reply_error(); return; };
Just a thought...
Also, in your example, failure_route[1] will be called for things like 404 (not found), and 486 (busy), and you will be attempting the same thing again using different media gateways etc...
I get around this by using a t_on_reply("1") and in onreply_route[1] do
if( status =~ "18[0-9]" ) { t_on_failure("0"); }
So if you get a provisional response from your media gateway (ie a 180 Ringing, or 183 Session Progress) you don't do any more gateway attempts if you then get a 4xx/5xx/6xx response....
You may also wish in route{} to split out the handling of CANCEL, BYE, and INVITE. You want your INVITE to do the ds_select_dst(), but you should just be able to t_relay() your CANCELs and BYEs and OpenSER will match them to the selected destination based on an existing transaction.
YMMV but this is similar to what I have been doing and testing with OpenSER.
Cheers, Peter
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users