Summary


Core dumps that occur in the field are often the result of a new call flow. However, when these core dumps occur, it is difficult to quickly confirm which new call flow caused the crash as there is no stored information relating to the sent and received network packets that comprise the call.

This facility enables memory based storage of recently sent and received SIP packets. In order to constrain the amount of system memory used, by default, only the data for recent calls are stored. This data is captured in the SCM process. 

Whether or not to save packets for stable calls or completed calls is specified in the configuration parameters.

In the event that a crash occurs, a tool is provided to extract this saved packet data from the core dump, and to provide the full contents of each packet of the SIP call flow for each call that was present on the system when the crash occurred.


Configuration Parameters

% set global saveRecentCallFlowsInMemory
	maxMemoryUsage <512-1048576>
	saveCallFlows <false | true>
	storeDataForCompletedCalls <false | true>
	storeDataForStableCalls <false | true>

Defaults per Personality Type

Whether the feature is turned on by default depends on the personality type and the platform.

When the feature is turned on by default, the maxMemoryUsage is set to 5% of the available memory.

Defaults per Personality Type:

Personality

Hardware Platforms

Virtual SWe

Cloud

I-SBC

EnabledNot available in the CLIAvailable
S-SBCEnabledNot available in the CLIAvailable
M-SBCNot available in the CLINot available in the CLINot available in the CLI

Defaults After Software Upgrade

When upgrading to this release, the defaults for saveCallFlowsInMemory are set to the same as a fresh install.

Reporting Tool

Note

Only core files generated from the ScmProcess contain call data.


When the reporting tool "printSavedCallFlows.py" is run without switches, it prints a summary of each call, such as the following:

Call Flows Summary:

Gcid 16777221: Call time: 02/04/2019 11:38:37 EST
Gcid 16777222: Call time: 02/04/2019 11:51:16 EST

When the reporting tool is run with the -g <GCID> switch, the reporting tool prints the complete PDUs for the call.


Example
Gcid 10: Call time: 02/05/2019 01:24:52 EST
Packet 1: IN
INVITE sip:1234567890@10.2.0.182:5060 SIP/2.0
Via: SIP/2.0/UDP 10.2.0.169:5060;branch=z9hG4bK-9406-1-0
From: <sip:5996543201@10.2.0.169:5060>;tag=9406SIPpTag001
To: sut <sip:5994567890@10.2.0.182:5060>
Call-ID: 1-9406@10.2.0.169
CSeq: 1 INVITE
Supported: timer
Session-Expires: 120
Allow: OPTIONS, CANCEL, ACK, BYE, INFO
Proxy-Authorization: Digest username=\"<username>\",realm=\"example.com\",nonce=\"923749873894\",opaque=\"\",uri=\"sip:+7326794285@example.com\",response=\"9273498349838974\",algorithm=MD5
Accept: application/sdp
Contact: sip:sipp@10.2.0.169:5060
Route: <sip:123456789@20.20.20.20:5060>;lr
P-Asserted-Identity: \"Sample\" <sip:user0user1user2user3user4user5user6user7user8user9user0user1user2user3user4user5user6user7user8user9user0user1user2@sonusnet.com>,\"9876543210\" <tel:9876543212;cpc=payphone>
Diversion: <sip:1234567890@10.2.0.182:5060>;reason=\"sdfff-sdf\";counter=1;privacy=off, <sip:2222@10.1.1.1>;counter=1;privacy=off
P-Charging-Vector: icid-value=0fa92f5c-0000-1000-8000-0003bae278c0;icid-generated-at=10.32.200.42
Remote-Party-ID: \"<example>\" <sip:5490001001@10.32.200.42:5060>;id-context=plain;privacy=off
P-K-Cfo: <tel: +19786418260 >;p=\"y\";r=\"msnr\";ap=n;ad=+19786148888
Content-Type: application/sdp


The full help for the utility is shown below:

usage: printSavedCallFlows.py [-h] [-a] [-e EXECUTABLE] [-g GCID] [-l LAST]
[-n NUMBER] [-o OUTPUT] [-p PID] [-s STARTTIME]
[-t ENDTIME] [-v] [-x] [-y] [-z]
[corefile]
Read saved call flows from a core dump
positional arguments:
corefile The corefile to be analyzed
optional arguments:
-h, --help show this help message and exit
-a, --all Print all call flows
-e EXECUTABLE, --executable EXECUTABLE
The executable associated with the corefile
default:/opt/sonus/sbx/bin/ScmProcess
-g GCID, --gcid GCID Print the call flow for the gcid (global call id)
default: print a summary of all call flows
-l LAST, --last LAST print the last n callflows
-n NUMBER, --number NUMBER
Only print the first n packets from each call flow
-o OUTPUT, --output OUTPUT
output file for results
-p PID, --pid PID Print call flows with a time greater than this value
-s STARTTIME, --starttime STARTTIME
Print call flows with a time greater than this value
-t ENDTIME, --endtime ENDTIME
print call flows with a time less than this value
-v, --verbose Enable verbose mode
-x, --headersOnly Only print packet headers
-y, --summary Only print only gcid, timestamp for each call flow
-z, --state Print the state for each call flow