Problem with Asterisk AMI after switching from chan_sip (Asterisk 18.8.0) to pjsip (Asterisk 22.7.0)

debug_PJSIP.txt (162.9 KB)

And when direct media is enabled but not set to use update, does it work?

Yes, but the connection is terminating after 30 seconds.

This doesn’t happen when direct media is off.

I’d suggest providing logs of that scenario as well as when direct media is not enabled so the differences can be compared.

debug_PJSIP_direct_media_invite.txt (729.8 KB)

debug_PJSIP_direct_media_off.txt (681.1 KB)

In the direct media with INVITE case the remote side is not responding to the re-INVITE. Retransmissions occur, then times out and the session terminates.

The UPDATE case I think is a race condition in Asterisk. You can file an issue[1] but there is no time frame on when it would get looked into, or if it would.

[1] GitHub · Where software is built

Thanks for the support. I initially continue to use channel sip (with Asterisk 20.18.2).

You don’t need to use that older Asterisk version you can use version 22.8 if you like, just add chan_sip back in, it’s easy, see: