Hello,
I am new to opensips. I went through proxy tutorials and now I am trying to
configure opensips in b2bua mode. I am using 3 dockers (UAS, UAC and
opensips).
I have problems with BYE message sent by UAC. Opensips is not able to match
it to whole dialog (this is my interpretation) and returns 500 internal
error (due to t_relay call, but without it there is no response at all).
What am I missing from my config ?
Thanks for any hint
# UAS at 172.18.0.4:
$ sipp --t tn -sn uas
# UAC at 172.18.0.3
$ sipp -t tn -rsa 172.18.0.2 -sn uac -r 1 172.18.0.4
# opensips 2.4.4 (x86_64/linux) at 172.18.0.2
opensips.cfg
### Modules Section
#set module path
mpath="/usr/lib/x86_64-linux-gnu/opensips/modules/"
StateLess module
loadmodule "sl.so"
Transaction Module
loadmodule "tm.so"
modparam("tm", "fr_timeout", 5)
modparam("tm", "fr_inv_timeout", 30)
modparam("tm", "restart_fr_on_each_reply", 0)
modparam("tm", "onreply_avp_mode", 1)
Record Route Module
loadmodule "rr.so"
modparam("rr", "append_fromtag", 0)
SIP MSG OPerationS module
loadmodule "sipmsgops.so"
FIFO Management Interface
loadmodule "mi_fifo.so"
modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")
modparam("mi_fifo", "fifo_mode", 0666)
TCP protocol
loadmodule "proto_tcp.so"
loadmodule "topology_hiding.so"
loadmodule "b2b_entities.so"
loadmodule "b2b_logic.so"
modparam("tm", "pass_provisional_replies", 1)
### Routing Logic
route{
route(relay);
}
route[b2b_request] {
xlog("B2B request - callid: $ci time [$Tf] method ($rm) r-uri ($ru) 2nd
via ($hdr(via[1]))\n");
}
route[b2b_reply] {
xlog("B2B reply - callid %ci time [$Tf] method ($rm) r-uri ($ru) 2nd via
($hdr(via[1]))\n");
}
route[relay] {
if (is_method("INVITE") && !($si=="172.18.0.2" && $sp==5060))
{
xlog("B2B init - callid $ci time [$Tf] method ($rm) r-uri
($ru) 2nd via ($hdr(via[1]))\n");
b2b_init_request("top hiding");
exit;
}
xlog("t_relay - callid $ci time [$Tf] method ($rm) r-uri ($ru) 2nd
via ($hdr(via[1]))\n");
if (!t_relay())
{
sl_reply_error();
};
exit;
}
//NGREP/
T 172.18.0.3:60750 -> 172.18.0.2:5060 [AP]
INVITE sip:service@172.18.0.4:5060 SIP/2.0.
Via: SIP/2.0/TCP 172.18.0.3:5060;branch=z9hG4bK-382-1-0.
From: sipp ;tag=382SIPpTag001.
To: sut .
Call-ID: 1-382@172.18.0.3.
CSeq: 1 INVITE.
Contact: sip:sipp@172.18.0.3:5060.
Max-Forwards: 70.
Subject: Performance Test.
Content-Type: application/sdp.
Content-Length: 131.
.
v=0.
o=user1 53655765 2353687637 IN IP4 172.18.0.3.
s=-.
c=IN IP4 172.18.0.3.
t=0 0.
m=audio 6000 RTP/AVP 0.
a=rtpmap:0 PCMU/8000.
T 172.18.0.2:5060 -> 172.18.0.3:60750 [AP]
SIP/2.0 100 Giving a try.
Via: SIP/2.0/TCP 172.18.0.3:5060;branch=z9hG4bK-382-1-0.
From: sipp ;tag=382SIPpTag001.
To: sut .
Call-ID: 1-382@172.18.0.3.
CSeq: 1 INVITE.
Server: OpenSIPS (2.4.4 (x86_64/linux)).
Content-Length: 0.
.
T 172.18.0.2:43989 -> 172.18.0.4:5060 [AP]
INVITE sip:service@172.18.0.4:5060 SIP/2.0.
Via: SIP/2.0/TCP 172.18.0.2:5060;branch=z9hG4bK0c85.96049b37.0.
To: sip:service@172.18.0.4:5060.
From: sipp ;tag=42494589cc6520b7535401b81466113d.
CSeq: 2 INVITE.
Call-ID: B2B.95.8135310.1549535500.
Max-Forwards: 70.
Content-Length: 131.
User-Agent: OpenSIPS (2.4.4 (x86_64/linux)).
Content-Type: application/sdp.
Contact: .
.
v=0.
o=user1 53655765 2353687637 IN IP4 172.18.0.3.
s=-.
c=IN IP4 172.18.0.3.
t=0 0.
m=audio 6000 RTP/AVP 0.
a=rtpmap:0 PCMU/8000.
T 172.18.0.4:5060 -> 172.18.0.2:43989 [AP]
SIP/2.0 180 Ringing.
Via: SIP/2.0/TCP 172.18.0.2:5060;branch=z9hG4bK0c85.96049b37.0.
From: sipp ;tag=42494589cc6520b7535401b81466113d.
To: sip:service@172.18.0.4:5060;tag=370SIPpTag0130.
Call-ID: B2B.95.8135310.1549535500.
CSeq: 2 INVITE.
Contact: .
Content-Length: 0.
.
T 172.18.0.4:5060 -> 172.18.0.2:43989 [AP]
SIP/2.0 200 OK.
Via: SIP/2.0/TCP 172.18.0.2:5060;branch=z9hG4bK0c85.96049b37.0.
From: sipp ;tag=42494589cc6520b7535401b81466113d.
To: sip:service@172.18.0.4:5060;tag=370SIPpTag0130.
Call-ID: B2B.95.8135310.1549535500.
CSeq: 2 INVITE.
Contact: .
Content-Type: application/sdp.
Content-Length: 131.
.
v=0.
o=user1 53655765 2353687637 IN IP4 172.18.0.4.
s=-.
c=IN IP4 172.18.0.4.
t=0 0.
m=audio 6000 RTP/AVP 0.
a=rtpmap:0 PCMU/8000.
T 172.18.0.2:5060 -> 172.18.0.3:60750 [AP]
SIP/2.0 180 Ringing.
Via: SIP/2.0/TCP 172.18.0.3:5060;branch=z9hG4bK-382-1-0.
From: sipp ;tag=382SIPpTag001.
To: sut ;tag=B2B.407.108.1549535500.
Call-ID: 1-382@172.18.0.3.
CSeq: 1 INVITE.
Contact: .
Server: OpenSIPS (2.4.4 (x86_64/linux)).
Content-Length: 0.
.
T 172.18.0.2:5060 -> 172.18.0.3:60750 [AP]
SIP/2.0 200 OK.
Via: SIP/2.0/TCP 172.18.0.3:5060;branch=z9hG4bK-382-1-0.
From: sipp ;tag=382SIPpTag001.
To: sut ;tag=B2B.407.108.1549535500.
Call-ID: 1-382@172.18.0.3.
CSeq: 1 INVITE.
Content-Type: application/sdp.
Contact: .
Server: OpenSIPS (2.