Troubleshoot SIP call flows
Learn how to use features within the High Performance Extensible Logging (HPEL) log and trace infrastructure to troubleshoot SIP call flows across SIP proxies and SIP containers.
When HPEL is enabled for the SIP proxy and the SIP container, all log and trace records related to SIP message processing for the proxy and container include the SIP call identifier extension, SIPCallId. Because the SIPCallId extension is constant across all components within a SIP call flow, we can use this extension to track the call flow between a SIP proxy and container.
Other extensions are also available for the SIP container. To learn about other extensions available, see the log and trace extensions documentation.
Tasks
- Enable HPEL on the SIP proxy server and the SIP container server. Use the administrative console or wsadmin scripting to enable HPEL. See the documentation on using High Performance Extensible Logging to troubleshoot applications to learn how to enable and configure the HPEL facility. When possible, all log and trace records for the proxy and container now include the SIPCallId extension.
- Enable tracing for our SIP proxy server or SIP container. Use the administrative console to enable tracing for your SIP proxy server or SIP container. For more information about enabling tracing, see the tracing a SIP proxy server documentation or the tracing a SIP container documentation.
- Start traffic through the SIP container and proxy server.
- Use the logViewer command-line tool to query the contents of the HPEL log and trace repositories and view specific trace data with the SIPCallId extension.
To learn about how to use this tool to view HPEL log and trace data, see the logViewer command-line tool documentation.
The following examples illustrate how to use the logViewer tool to see the call flow data where the SIPCallId extension is used.
- To return all log entries that have the SIPCallId extension set:(Windows)
bin\logViewer.bat -includeExtensions SIPCallId(UNIX) (Linux)bin/logViewer.sh -includeExtensions SIPCallId(ZOS)bin/logViewer.sh -includeExtensions SIPCallId -instance <instanceid>The SIPCallId extension is not visible when we use this command.- To return all log entries in the advanced format which includes all of the trace extension information:(Windows)
bin\logViewer.bat -format advanced(UNIX) (Linux)bin/logViewer.sh -format advanced(ZOS)bin/logViewer.sh -format advanced -instance <instanceid>.- To return all log entries with the SIPCallId extension and all of the trace extension information:(Windows)
bin\logViewer.bat -format advanced -includeExtensions SIPCallId(UNIX) (Linux)bin/logViewer.sh -format advanced -includeExtensions SIPCallId(ZOS)bin/logViewer.sh -format advanced -includeExtensions SIPCallId -instance <instanceid>.- To filter on a specific SIPCallId extension to return all log entries with SIPCallId set to a specific identifier. (Windows)
bin\logViewer.bat -includeExtensions SIPCallId=specificid(UNIX) (Linux)bin/logViewer.sh -includeExtensions SIPCallId=specificid(ZOS)bin/logViewer.sh -includeExtensions SIPCallId=specificid -instance <instanceid>.
We are ready to view query results. The log viewer dumps the results of the query to the administrative console. We can choose to redirect the query results to a text file by piping the results to a specified file. If performance is not a concern, we can enable the HPEL text log and change it to the advanced format. Using the advanced format, HPEL stores the SIPCalId extensions.
Example
The following example illustrates how to troubleshoot a call flow when the SIPCallId extension is included in trace data when we are running in UNIX environments. These examples can extend to the Windows and z/OS operating systems.
- Determine the SIP Call identifier in question. If we do not know the Call identifier, we can use the following command to view all traces for all the call identifiers in the logs: (UNIX) (Linux)
logViewer.sh -format advance -includeExtensions SIPCallIdThe output of this command is in the advanced format and includes the additional information available including the SIPCallId; for example:[10/2/12 13:23:08:634 EDT] 00000084 > UOW= source=com.ibm.ws.proxy.channel.sip.SipProxyConnection method=messageReceivedThreaded org=IBM prod=WebSphere component=Application Server thread=[UDP Thread Pool : 0] SIPCallId=[1-23304@9.37.23.235] Entry [10/2/12 13:23:08:634 EDT] 00000084 > UOW= source=com.ibm.ws.proxy.channel.sip.SipProxyConnection method=readIndication: id = 1282434117 org=IBM prod=WebSphere component=Application Server thread=[UDP Thread Pool : 0] SIPCallId=[1-23304@9.37.23.235] Entry [10/2/12 13:23:08:634 EDT] 00000084 3 UOW= source=com.ibm.ws.proxy.channel.sip.SipProxyConnection org=IBM prod=WebSphere component=Application Server thread=[UDP Thread Pool : 0] SIPCallId=[1-23304@9.37.23.235] Received Message from 9.37.23.235:10200 - [10/2/12 13:23:08:634 EDT] 00000084 3 UOW= source=com.ibm.ws.proxy.channel.sip.SipProxyConnection org=IBM prod=WebSphere component=Application Server thread=[UDP Thread Pool : 0] SIPCallId=[1-23304@9.37.23.235] Message received from CLIENT: [10/2/12 13:23:08:634 EDT] 00000084 3 UOW= source=com.ibm.ws.proxy.channel.sip.SipProxyConnection org=IBM prod=WebSphere component=Application Server thread=[UDP Thread Pool : 0] SIPCallId=[1-23304@9.37.23.235] Received Message from 9.37.23.235:10200 -- Filter the logs that are based on a specific call identifier using the following command: (UNIX) (Linux)
bin/logViewer.sh -includeExtensions SIPCallId=1-23304@9.37.23.235The results of the command are in the basic format and shows log entries typical for SIP proxy log. The output is filtered on the specified SIPCallId extension.[10/2/12 13:23:08:634 EDT] 00000084 SipProxyConne > messageReceivedThreaded Entry [10/2/12 13:23:08:634 EDT] 00000084 SipProxyConne > readIndication: id = 1282434117 Entry [10/2/12 13:23:08:634 EDT] 00000084 SipProxyConne 3 Received Message from 9.37.23.235:10200 - [10/2/12 13:23:08:634 EDT] 00000084 SipProxyConne 3 Message received from CLIENT: [10/2/12 13:23:08:634 EDT] 00000084 SipProxyConne 3 Received Message from 9.37.23.235:10200 - [10/2/12 13:23:08:634 EDT] 00000084 SIPMessageImp > getDuplicate Entry [10/2/12 13:23:08:634 EDT] 00000084 SIPMessageFac > SipMessageFactoryImpl:getRef entry Entry [10/2/12 13:23:08:634 EDT] 00000084 SIPMessageFac < SipMessageFactoryImpl:getRef: exit: Exit
Subtopics
- Log and Trace extensions
The High Performance Extensible Logging (HPEL) capability in the application server provides a way for developers to add extension fields to log and trace records, and a corresponding way for you to filter log and trace records by extension value.
Related:
High Performance Extensible Logging (HPEL) Use High Performance Extensible Logging to troubleshoot applications Change from basic mode to HPEL logging and tracing Tracing a SIP proxy server Tracing a SIP container logViewer command-line tool Log and Trace extensions