Am 14.03.2011 20:35, schrieb Asgaroth:
Hi All,
I have a scenario where I have 2 asterisk media servers that, when calling a registered sip account, will forward off the invite to a location server, who looks up the contact information, then forwards the invite off to the proxy that the user registered against (done via the path module). This all appears to work perfectly until the us hangs up the call. The BYE message does not make it all the way back to the originating asterisk media server, it makes it back to the location server that looked up the registration information.
To overcome this issue, I add a "Record-Route" header specifying the address of the asterisk media server that the request originated from. However, when I add the custom header, the Invite shows up as fragmented packet my wire-shark trace at the end-user's soft-phone. The call sets up properly and when I hang up it looks like the BYE message makes it all the way back to the media server, but when it is relayed on the the caller, the sip proxy then fails the call with a message too big. If I remove the line that adds the record-route header, then all looks fine, except that I am unable to tear down calls from sip end-points.
The specific line I'm using to add the header is as follows:
insert_hf("Record-Route: sip:$si:$sp;lr=on\r\n","Record-Route");
sounds like you are using the internal record_route() function and adding header manually. This might cause problems. If you play around with RR headers, just add them all manually.
Probably you have 2 issues: 1. bad in-dialog routing back to your Asterisk server, 2. fragmentation problem.
Fragmentation shouldn't be a problem, all devices should handle them (I personally never had any issues). If you need to reduce the packet size you can try to remove unneeded headers and remove unused codecs from the SDP.
But back to the original issues. You said, that the BYE (should be loose routed) is not routed correctly back to the Asterisk server. Fix this - as this is your real problem. Take a look at the contact headers and in-dialog request URIs. Then you need not play around with faked record-route headers.
If you need help, post an ngrep trace (or pcap file) of the scenario:
ngrep -W byline -t -q -P "" port 5060
regards klaus
I do remove this from the route header on in-dialog replies as loose-route does not remove the header on the original location server as it does not see the route header as local, so I manually remove it.
Has anyone come across this particular issue? I'm using Kamailio 3.1.2. Am I going about this is the wrong way? I've been reading the module docs for registrar/usrloc/rr/path/textops to see if there is something I've missed but cannot see it.
Any tips/suggestions would be greatly appreciated.
Thanks
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users