Hi All I was able to setup carrierroute in database mode and when I make a call with prefix 00 it works fine. For that I did setup an entry in carrierroute, I did duplicate that same entry for prefix "+". If I call 004353453 it works fine however if I dial +12341234 I get a 403 forbidden error. The log shows:
Jan 23 14:22:34 [25866] DBG:carrierroute:get_route_tree_by_id: tree default, domain 0 : 0 Jan 23 14:22:34 [25866] INFO:carrierroute:rewrite_uri_recursor: URI or route tree nodes empty, empty flag list Jan 23 14:22:34 [25866] INFO:carrierroute:cr_do_route: rewrite_uri_recursor doesn't complete, uri +9613041705, carrier 5, domain 0
Any guidance please ?
With Regards
On Friday 23 January 2009, Ali Jawad wrote:
I was able to setup carrierroute in database mode and when I make a call with prefix 00 it works fine. For that I did setup an entry in carrierroute, I did duplicate that same entry for prefix "+". If I call 004353453 it works fine however if I dial +12341234 I get a 403 forbidden error. The log shows:
Jan 23 14:22:34 [25866] DBG:carrierroute:get_route_tree_by_id: tree default, domain 0 : 0 Jan 23 14:22:34 [25866] INFO:carrierroute:rewrite_uri_recursor: URI or route tree nodes empty, empty flag list Jan 23 14:22:34 [25866] INFO:carrierroute:cr_do_route: rewrite_uri_recursor doesn't complete, uri +9613041705, carrier 5, domain 0
Hi Ali,
cr was designed for numerical route matching, so the '+' will not work in 1.4.x. (In the trunk version you can also configure non numerical matching.) I'd suggest that you sanitize incoming R-URI users (remove '+', remove '0' prefix etc..), and just use a format like this: 4912341234567.
Cheers,
Henning
Hi THanks for that update. Is there a way to automatically set the probality of one to the servers to 0, if it is down returning failed calls ? Thanks
-----Original Message----- From: Henning Westerholt [mailto:henning.westerholt@1und1.de] Sent: 2009-01-23 16:50 To: users@lists.kamailio.org Cc: Ali Jawad Subject: Re: [Kamailio-Users] CarrierRoute With + Prefix
On Friday 23 January 2009, Ali Jawad wrote:
I was able to setup carrierroute in database mode and when I make a call with prefix 00 it works fine. For that I did setup an entry in carrierroute, I did duplicate that same entry for prefix "+". If I call 004353453 it works fine however if I dial +12341234 I get a 403 forbidden error. The log shows:
Jan 23 14:22:34 [25866] DBG:carrierroute:get_route_tree_by_id: tree default, domain 0 : 0 Jan 23 14:22:34 [25866] INFO:carrierroute:rewrite_uri_recursor: URI or route tree nodes empty,
empty flag list Jan 23 14:22:34 [25866] INFO:carrierroute:cr_do_route: rewrite_uri_recursor doesn't complete, uri +9613041705, carrier 5, domain 0
Hi Ali,
cr was designed for numerical route matching, so the '+' will not work in 1.4.x. (In the trunk version you can also configure non numerical matching.) I'd suggest that you sanitize incoming R-URI users (remove '+', remove '0' prefix etc..), and just use a format like this: 4912341234567.
Cheers,
Henning
On Friday 23 January 2009, Ali Jawad wrote:
Hi THanks for that update. Is there a way to automatically set the probality of one to the servers to 0, if it is down returning failed calls ? Thanks
No, functionality like this is provided from the dispatcher module. If you want to implement something similar to this with cr, you need to write some scripts.
Cheers,
Henning
Hi Again
I did use if($rU =~ "^[+].*") {
strip(1);
}
before the cr statement ...from asterisk I get address incomplete at times..when this happens I find that the first two characters are stripped instead of only the first one.
Any clues ?
Thanks
-----Original Message----- From: Henning Westerholt [mailto:henning.westerholt@1und1.de] Sent: 2009-01-23 17:04 To: Ali Jawad Cc: users@lists.kamailio.org Subject: Re: [Kamailio-Users] CarrierRoute With + Prefix
On Friday 23 January 2009, Ali Jawad wrote:
Hi THanks for that update. Is there a way to automatically set the probality of one to the servers to 0, if it is down returning failed calls ? Thanks
No, functionality like this is provided from the dispatcher module. If you want to implement something similar to this with cr, you need to write some scripts.
Cheers,
Henning
On Fri, Jan 23, 2009 at 1:14 PM, Ali Jawad ali.jawad@splendor.net wrote:
Hi Again
I did use if($rU =~ "^[+].*") {
strip(1); }
before the cr statement ...from asterisk I get address incomplete at times..when this happens I find that the first two characters are stripped instead of only the first one.
Any clues ?
Check if your request is not passing twice by same place. A log sentence before strip could help.
If it strips the first + it should not re-enter the if condition because the + has been removed at that stage right ? Thanks
-----Original Message----- From: Luciano Afranllie [mailto:listas.luafran@gmail.com] Sent: 2009-01-23 17:20 To: Ali Jawad Cc: Henning Westerholt; users@lists.kamailio.org Subject: Re: [Kamailio-Users] CarrierRoute With + Prefix
On Fri, Jan 23, 2009 at 1:14 PM, Ali Jawad ali.jawad@splendor.net wrote:
Hi Again
I did use if($rU =~ "^[+].*") {
strip(1); }
before the cr statement ...from asterisk I get address incomplete at times..when this happens I find that the first two characters are stripped instead of only the first one.
Any clues ?
Check if your request is not passing twice by same place. A log sentence before strip could help.
On Fri, Jan 23, 2009 at 1:35 PM, Ali Jawad ali.jawad@splendor.net wrote:
If it strips the first + it should not re-enter the if condition because the + has been removed at that stage right ? Thanks
You are right, my comment was stupid ;)
-----Original Message----- From: Luciano Afranllie [mailto:listas.luafran@gmail.com] Sent: 2009-01-23 17:20 To: Ali Jawad Cc: Henning Westerholt; users@lists.kamailio.org Subject: Re: [Kamailio-Users] CarrierRoute With + Prefix
On Fri, Jan 23, 2009 at 1:14 PM, Ali Jawad ali.jawad@splendor.net wrote:
Hi Again
I did use if($rU =~ "^[+].*") {
strip(1); }
before the cr statement ...from asterisk I get address incomplete at times..when this happens I find that the first two characters are stripped instead of only the first one.
Any clues ?
Check if your request is not passing twice by same place. A log sentence before strip could help.
On Friday 23 January 2009, Ali Jawad wrote:
I did use if($rU =~ "^[+].*") {
strip(1); }
before the cr statement ...from asterisk I get address incomplete at times..when this happens I find that the first two characters are stripped instead of only the first one.
Try this:
if (uri =~ "^sip:+") { strip(1); }
Cheers,
Henning