[sr-dev] [kamailio/kamailio] Use kamilio to deploy as P-cscf, I-cscf, S-cscf to implement IMS functions. In the SIP call Flow , the P-CSCF will exit every time. (#2267)

chenhao5651 notifications at github.com
Mon Mar 30 10:17:18 CEST 2020


<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for bug reports.

If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:

  * http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:

  * http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev

Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.

If there is no content to be filled in a section, the entire section can be removed.

You can delete the comments from the template sections when filling.

You can delete next line and everything above before submitting (it is a comment).
-->

### Description

I use kamilio to deploy as P-cscf, I-cscf,S-cscf to implement IMS functions, two test phones attach kamilio and make volte call. The P-cscf will exit every time.

### Troubleshooting

I think it may related to the collaboration between tm module and ipsec module.

#### Reproduction
I set up a test environment according to the instructions https://open5gs.org/open5gs/docs/tutorial/02-VoLTE-setup/ . two iphones connetc to the EPC and attach to kamailio,and the IPSec is available. 

#### Debugging Data
Here is the gdb info
```
Reading symbols from /usr/local/sbin/kamailio...done.
[New LWP 22934]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/local/sbin/kamailio -f /etc/kamailio_pcscf/kamailio_pcscf.cfg -P /var/run/'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007f1f4951f2d0 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
(gdb) bt
#0  0x00007f1f4951f2d0 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007f1f494cefb4 in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6
#2  0x00007f1f494d1370 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#3  0x00007f1f494ce7ea in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6
#4  0x00007f1f494d78c4 in fprintf () from /lib/x86_64-linux-gnu/libc.so.6
#5  0x00007f1f44290629 in fill_contact (ci=0x7fff6d0ae1a0, m=0x7f1f48ee3280) at cmd.c:218
#6  0x00007f1f4429a29a in ipsec_forward (m=0x7f1f48ee3280, d=0x7f1f44a7efb8) at cmd.c:693
#7  0x00007f1f442890ac in w_forward (_m=0x7f1f48ee3280, _d=0x7f1f44a7efb8 "\270\356\247D\037\177", _cflags=0x0) at ims_ipsec_pcscf_mod.c:355
#8  0x000055713f26f2f1 in do_action (h=0x7fff6d0af080, a=0x7f1f48e7d3d8, msg=0x7f1f48ee3280) at core/action.c:1079
#9  0x000055713f27d2ab in run_actions (h=0x7fff6d0af080, a=0x7f1f48e79710, msg=0x7f1f48ee3280) at core/action.c:1578
#10 0x000055713f27dabd in run_top_route (a=0x7f1f48e79710, msg=0x7f1f48ee3280, c=0x7fff6d0af080) at core/action.c:1663
#11 0x00007f1f489dd18a in reply_received (p_msg=0x7f1f48ee3280) at t_reply.c:2418
#12 0x000055713f382183 in do_forward_reply (msg=0x7f1f48ee3280, mode=0) at core/forward.c:745
#13 0x000055713f383fcb in forward_reply (msg=0x7f1f48ee3280) at core/forward.c:846
#14 0x000055713f3e82a9 in receive_msg (
    buf=0x55713f6c9ea0 <buf> "SIP/2.0 183 Session Progress\r\nRecord-Route: <sip:mt at 192.168.4.207;transport=tcp;r2=on;lr=on;ftag=2573636716;rm=7;did=a1e.1e8>,<sip:mt at 192.168.4.207;r2=on;lr=on;ftag=2573636716;rm=7;did=a1e.1e8>,<sip:m"..., len=1958, rcv_info=0x7fff6d0af5c0) at core/receive.c:510
#15 0x000055713f2d05e1 in udp_rcv_loop () at core/udp_server.c:548
#16 0x000055713f233c1e in main_loop () at main.c:1673
#17 0x000055713f23cff2 in main (argc=13, argv=0x7fff6d0afea8) at main.c:2802

```

#### Log Messages
Here is the P-cscf logs
[pcscf.log](https://github.com/kamailio/kamailio/files/4401553/pcscf.log)

#### SIP Traffic


[traffic.zip](https://github.com/kamailio/kamailio/files/4401567/traffic.zip)

### Possible Solutions

<!--
If you found a solution or workaround for the issue, describe it. Ideally, provide a pull request with a fix.
-->

### Additional Information

  * **Kamailio Version** - output of `kamailio -v`

```
(paste your output here)
```

* **Operating System**:

<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->

```
(paste your output here)
```


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2267
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20200330/6f86dcc5/attachment-0001.html>


More information about the sr-dev mailing list