[SR-Users] Help with 200k responses to the contact header not the record-route

Daniel-Constantin Mierla miconda at gmail.com
Tue Oct 29 10:24:36 CET 2013


Hello,

On 10/24/13 3:49 PM, anfecora wrote:
> Hi all, can anyone help me to find out what is wrong with my setup, i 
> have an asterisk behind a kamailio, kamailio is proxying all packages 
>  to the outside.
>
> when the call is bridge it gets disconnected after a few seconds, it 
> seems that our voip carrier is sending a bye because we didn't answer 
> to their 200 ok properly, but as the trace shows we did only that 
> kamailio is answering to the contact header ip not the ip that is 
> sending the ok.


the ACK has to be forwarded where the INVITE was forwarded, not where 
the 200ok was forwarded.

We need full ngrep trace, from INVITE to BYE to see the contact and 
record-route headers in INVITE/200ok in order to state what part of the 
routing is going wrong there.

Cheers,
Daniel

>
> I am sorry i sent a too long message before i will try skim it a bit.
>
> any help is appreciated .
>
> thanks.
>
> my setup
>
> request_route {
>
> if (!mf_process_maxfwd_header("10")) {
>         sl_send_reply("483","Too Many Hops");
>             exit;
> }
>
>
> if(is_method("OPTIONS")) {
>         # send reply for each options request
>     sl_send_reply("200", "ok");
>     exit();
>      }
>
>  if(method=="BYE") {
>  #Account BYE transactions
>
> };
>
>
> if (method=="CANCEL") {
> if (t_check_trans()) t_relay();
>
> exit;
> };
>
>
>
>  if (loose_route()) {
>
>
> t_relay();
>             exit;
>        }
>
>
>  if (is_method("INVITE")) {
>
>
>             record_route();
>
> }
> f (!t_relay_to_udp("3.1.1.1", "5060")) {
> sl_reply_error();
> exit;
> };
> exit
> };
>
> here is a trace to a call made to a hotel.
> i had changed the real ips for obvious reasons.
> thanks.
>
>
> asterisk ip 1.1.1.1
> kamailio internal 1.1.1.2
> kamailio external 2.0.0.1
> Voip Carrier 3.1.1.1
> voip contact ip 3.1.1.2
>
> U 2013/10/23 17:26:20.354248 1.1.1.2:5060 <http://1.1.1.2:5060> -> 
> 3.1.1.2:5060 <http://3.1.1.2:5060>
> ACK sip:76890723276341079 at 3.1.1.2:5060 
> <http://sip:76890723276341079@3.1.1.2:5060> SIP/2.0.
> Via: SIP/2.0/UDP 2.0.0.1:5060;branch=z9hG4bKcydzigwkX.
> Via: SIP/2.0/UDP 1.1.1.1:5060;branch=z9hG4bK280c4e9c;rport=5060.
> Route: 
> <sip:2.0.0.1;lr=on;ftag=as4bc322e9>,<sip:3.1.1.1;lr;ftag=as4bc322e9;did=8b8.d7ef5a05>.
> Max-Forwards: 16.
> From: "+19812457865" <sip:+19812457865 at 1.1.1.1 
> <mailto:sip%3A%2B19812457865 at 1.1.1.1>>;tag=as4bc322e9.
> To: <sip:76890723276341079 at 3.1.1.2 
> <mailto:sip%3A76890723276341079 at 3.1.1.2>>;tag=3591552407-393967.
> Contact: <sip:+19812457865 at 1.1.1.1:5060 
> <http://sip:+19812457865@1.1.1.1:5060>>.
> Call-ID: 7d0ca48c1d48c14d104fac1f59194ae0 at 1.1.1.1:5060 
> <http://7d0ca48c1d48c14d104fac1f59194ae0@1.1.1.1:5060>.
> CSeq: 102 ACK.
> User-Agent: Asterisk PBX 1.8.15-cert2.
> Content-Length: 0.
> .
>
>
> U 2013/10/23 17:26:36.355580 3.1.1.1:5060 <http://3.1.1.1:5060> -> 
> 1.1.1.2:5060 <http://1.1.1.2:5060>
> BYE sip:+19812457865 at 1.1.1.1:5060 
> <http://sip:+19812457865@1.1.1.1:5060> SIP/2.0.
> Max-Forwards: 69.
> Route: <sip:2.0.0.1;lr=on;ftag=as4bc322e9>.
> To: "+19812457865" <sip:+19812457865 at 1.1.1.1 
> <mailto:sip%3A%2B19812457865 at 1.1.1.1>>;tag=as4bc322e9.
> From: <sip:76890723276341079 at 3.1.1.1 
> <mailto:sip%3A76890723276341079 at 3.1.1.1>>;tag=3591552407-393967.
> Call-ID: 7d0ca48c1d48c14d104fac1f59194ae0 at 1.1.1.1:5060 
> <http://7d0ca48c1d48c14d104fac1f59194ae0@1.1.1.1:5060>.
> CSeq: 2 BYE.
> Allow: INVITE, BYE, OPTIONS, CANCEL, ACK, REGISTER, NOTIFY, INFO, 
> REFER, SUBSCRIBE, PRACK, UPDATE.
> Via: SIP/2.0/UDP 3.1.1.1:5060;branch=z9hG4bKce8a.db93afa3.0.
> Via: SIP/2.0/UDP 
> 3.1.1.2:5060;branch=z9hG4bK96003ecbb11f5deaf6014235140e6952.
> Contact: <sip:76890723276341079 at 3.1.1.2:5060 
> <http://sip:76890723276341079@3.1.1.2:5060>>.
> Content-Length: 0.
>
> U 2013/10/23 17:26:20.354248 1.1.1.2:5060 <http://1.1.1.2:5060> -> 
> 3.1.1.2:5060 <http://3.1.1.2:5060>
> ACK sip:76890723276341079 at 3.1.1.2:5060 
> <http://sip:76890723276341079@3.1.1.2:5060> SIP/2.0.
> Via: SIP/2.0/UDP 2.0.0.1:5060;branch=z9hG4bKcydzigwkX.
> Via: SIP/2.0/UDP 1.1.1.1:5060;branch=z9hG4bK280c4e9c;rport=5060.
> Route: 
> <sip:2.0.0.1;lr=on;ftag=as4bc322e9>,<sip:3.1.1.1;lr;ftag=as4bc322e9;did=8b8.d7ef5a05>.
> Max-Forwards: 16.
> From: "+19812457865" <sip:+19812457865 at 1.1.1.1 
> <mailto:sip%3A%2B19812457865 at 1.1.1.1>>;tag=as4bc322e9.
> To: <sip:76890723276341079 at 3.1.1.2 
> <mailto:sip%3A76890723276341079 at 3.1.1.2>>;tag=3591552407-393967.
> Contact: <sip:+19812457865 at 1.1.1.1:5060 
> <http://sip:+19812457865@1.1.1.1:5060>>.
> Call-ID: 7d0ca48c1d48c14d104fac1f59194ae0 at 1.1.1.1:5060 
> <http://7d0ca48c1d48c14d104fac1f59194ae0@1.1.1.1:5060>.
> CSeq: 102 ACK.
> User-Agent: Asterisk PBX 1.8.15-cert2.
> Content-Length: 0.
> .
>
>
> U 2013/10/23 17:26:36.355580 3.1.1.1:5060 <http://3.1.1.1:5060> -> 
> 1.1.1.2:5060 <http://1.1.1.2:5060>
> BYE sip:+19812457865 at 1.1.1.1:5060 
> <http://sip:+19812457865@1.1.1.1:5060> SIP/2.0.
> Max-Forwards: 69.
> Route: <sip:2.0.0.1;lr=on;ftag=as4bc322e9>.
> To: "+19812457865" <sip:+19812457865 at 1.1.1.1 
> <mailto:sip%3A%2B19812457865 at 1.1.1.1>>;tag=as4bc322e9.
> From: <sip:76890723276341079 at 3.1.1.1 
> <mailto:sip%3A76890723276341079 at 3.1.1.1>>;tag=3591552407-393967.
> Call-ID: 7d0ca48c1d48c14d104fac1f59194ae0 at 1.1.1.1:5060 
> <http://7d0ca48c1d48c14d104fac1f59194ae0@1.1.1.1:5060>.
> CSeq: 2 BYE.
> Allow: INVITE, BYE, OPTIONS, CANCEL, ACK, REGISTER, NOTIFY, INFO, 
> REFER, SUBSCRIBE, PRACK, UPDATE.
> Via: SIP/2.0/UDP 3.1.1.1:5060;branch=z9hG4bKce8a.db93afa3.0.
> Via: SIP/2.0/UDP 
> 3.1.1.2:5060;branch=z9hG4bK96003ecbb11f5deaf6014235140e6952.
> Contact: <sip:76890723276341079 at 3.1.1.2:5060 
> <http://sip:76890723276341079@3.1.1.2:5060>>.
> Content-Length: 0.
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio Advanced Trainings - Berlin, Nov 25-28
   - more details about Kamailio trainings at http://www.asipto.com -

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20131029/1fa06230/attachment-0001.html>


More information about the sr-users mailing list