[Home]

Summary:ASTERISK-29003: Asterisk 13 PJSIP: Irregular Response to OPTION-Requests
Reporter:Christian Berger (Christian_Berger)Labels:
Date Opened:2020-07-22 05:17:52Date Closed:2020-08-05 12:00:01
Priority:TrivialRegression?
Status:Closed/CompleteComponents:Resources/res_pjsip
Versions:13.32.0 Frequency of
Occurrence
Frequent
Related
Issues:
Environment:Attachments:( 0) config_asterisk_13_pjsip_hfo.tar.gz
( 1) nagios.pcap
( 2) options_404.xml
Description:For some reason Asterisk with PJSIP often does not respond to SIP OPTION requests.

Whenever such a packet arrives it logs the following. However it often does not respond.
[Jul 22 11:17:32] DEBUG[30932] res_pjsip/pjsip_distributor.c: Could not find matching transaction for Request msg OPTIONS/cseq=1 (rdata0x7f4484310a88)
[Jul 22 11:17:32] DEBUG[30932] res_pjsip/pjsip_distributor.c: Calculated serializer pjsip/distributor-0000002a to use for Request msg OPTIONS/cseq=1 (rdata0x7f4484310a88)
[Jul 22 11:17:32] DEBUG[3442] netsock2.c: Splitting '213.167.166.18' into...
[Jul 22 11:17:32] DEBUG[3442] netsock2.c: ...host '213.167.166.18' and port ''.
[Jul 22 11:17:32] DEBUG[3442] res_pjsip_endpoint_identifier_ip.c: Source address 213.167.166.18:60860 matches identify 'sgw'
[Jul 22 11:17:32] DEBUG[3442] res_pjsip_endpoint_identifier_ip.c: Identify 'sgw' SIP message matched to endpoint sgw

Comments:By: Asterisk Team (asteriskteam) 2020-07-22 05:17:53.505-0500

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution. Please note that log messages and other files should not be sent to the Sangoma Asterisk Team unless explicitly asked for. All files should be placed on this issue in a sanitized fashion as needed.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

Please note that once your issue enters an open state it has been accepted. As Asterisk is an open source project there is no guarantee or timeframe on when your issue will be looked into. If you need expedient resolution you will need to find and pay a suitable developer. Asking for an update on your issue will not yield any progress on it and will not result in a response. All updates are posted to the issue when they occur.

By: Christian Berger (Christian_Berger) 2020-07-22 05:21:47.715-0500

This PCAP shows the traffic between a NAGIOS server and Asterisk. As you can see only part of the OPTION requests is answered. From what I can see all OPTION requests are logged. I cannot see any indication on why it is not answered.

The Asterisk instance is only very lightly loaded at 2 concurrent calls and perhaps a rejected call attempt every second or so.

By: Joshua C. Colp (jcolp) 2020-07-22 05:47:06.092-0500

Thank you for taking the time to report this bug and helping to make Asterisk better. Unfortunately, we cannot work on this bug because your description did not include enough information. Please read over the Asterisk Issue Guidelines [1] which discusses the information necessary for your issue to be resolved and the format that information needs to be in. We would be grateful if you would then provide a more complete description of the problem. At a minimum, we need:

1. The specific steps or actions you took that caused you to encounter the problem.
2. The behavior you expected and the location of documentation that led you to that expectation.
3. The behavior you actually encountered.

To demonstrate the issue in detail, please include Asterisk log files generated per the instructions on the wiki [2]. If applicable, please ensure that protocol-level trace debugging is enabled, e.g., 'sip set debug on' if the issue involves chan_sip, and configuration information such as dialplan and channel configuration.

Thanks!

[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines

[2] https://wiki.asterisk.org/wiki/display/AST/Collecting+Debug+Information

As well this does not seem to be a widespread issue with OPTIONS requests, so it is likely something specific to your environment or something else so we need all the information possible.

By: Christian Berger (Christian_Berger) 2020-07-22 05:53:02.347-0500

Essentially this bug can be reproduced by simply running an Asterisk, and sending OPTION packets to it. As far as I know there is no way to control this via any kind of configuration.

By: Joshua C. Colp (jcolp) 2020-07-22 06:03:38.913-0500

It's not as simple as that. I just started up a latest Asterisk 13 and hit it with a ton of OPTIONS requests simultaneously[1], more than you are doing (I'm doing 10 per second), and did not experience the problem. All received a SIP response. This issue also hasn't been reported by any other Asterisk user from what I can see. So that means something about your setup is unique. That could be your specific configuration, or it could even be the OPTIONS being produced but they don't look out of the ordinary.

[1] https://github.com/asterisk/testsuite/blob/master/tests/channels/pjsip/handle_options_request/sipp/options_404.xml

By: Christian Berger (Christian_Berger) 2020-07-22 06:55:29.047-0500

I have attached our configuration files.

By: Joshua C. Colp (jcolp) 2020-07-22 07:09:53.243-0500

Even with the configuration and modifying the SIPp scenario to better match, I'm unable to reproduce the issue. I've attached the SIPp scenario that I'm using. It can be executed by installing the sipp application and executing:

sipp -sf options_404.xml <IP address to send to>

Does it also experience the same issue as your Nagios? If you run it locally does it happen? If you run it remotely does it happen?

By: Asterisk Team (asteriskteam) 2020-08-05 12:00:00.926-0500

Suspended due to lack of activity. This issue will be automatically re-opened if the reporter posts a comment. If you are not the reporter and would like this re-opened please create a new issue instead. If the new issue is related to this one a link will be created during the triage process. Further information on issue tracker usage can be found in the Asterisk Issue Guidlines [1].

[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines