How to enable DICOM debugging mode and collect logs for Linux based systems

These are the steps to enable DICOM debugging mode and collect logs for Linux based systems

Details:

During this process, the Pureweb support team requires the following:

1. Ensure the server date/time is set correctly
2. Enable debugging for DICOM in the pureweb.log file
3. Tail the pureweb.log file (see below)
4. Optional : Start a network packet capture using tcpdump (Only as required-see below)
5. Reproduce the issue and write down the time of the issue.
6.  Send the following to Pureweb
        a. The date and time of the issue.
        b.  Steps used to reproduce the issue.
        c. The complete pureweb.log files and the tcpdump file (Only if tcpdump is performed and                required).

Below are the steps to enable Debugging Mode for both DICOM and URL Access on the server:
1. Log into the server web interface as the administrator.
2. Select Settings -> Advanced.
3. In the logback.xml file, locate the following text and change INFO and WARN to DEBUG.
<logger name="org.dcm4che2" level="WARN"/>
<logger name="org.dcm4che2.net.Association" level="INFO"/>
<logger name="pureweb.servlet.RequestLoggingFilter" level="INFO">
4. Save and go back to previous Settings -> Advanced screen.
 
The following setting is only required if the server runs with any version that is earlier than 6.0
5. Edit the logback.properties file and Change the following line (Log message layout change):
- layout=%d{ISO8601} %-5level %5X{PID} %logger{0} %msg%n
+ layout=%d{ISO8601} %thread %-5level %5X{PID} %logger{0} %msg%n
 
6. Save and go back to previous Settings -> Advanced screen.
7. Scroll down and click Reload Logging.
8. Logout and login again to refresh the web interface.

Here is an example of what we expect to see in the logs after enabling the  DICOM debugging logs: 
2017-10-11 08:39:27,634 RESMDWEB-184 INFO        PDUDecoder CIR_QUERY_SCP(180) >> 10:C-FIND-RSP[pcid=5, status=ff00H
>    cuid=1.2.840.10008.5.1.4.1.2.2.1/Study Root Query/Retrieve Information Model - FIND
>    ts=1.2.840.10008.1.2/Implicit VR Little Endian] 
2017-10-11 08:39:27,634 RESMDWEB-184 DEBUG       PDUDecoder Command:
>(0000,0002) UI #28 [1.2.840.10008.5.1.4.1.2.2.1] Affected SOP Class UID
>(0000,0100) US #2 [32800] Command Field
>(0000,0120) US #2 [10] Message ID Being Responded To
>(0000,0800) US #2 [256] Command Data Set Type
>(0000,0900) US #2 [65280] Status

2017-10-11 08:39:27,634 RESMDWEB-184 DEBUG       PDUDecoder CIR_QUERY_SCP(180) waiting for PDU
2017-10-11 08:39:27,634 RESMDWEB-184 DEBUG       PDUDecoder CIR_QUERY_SCP(180) >> PDU[type=4, len=346]
2017-10-11 08:39:27,634 RESMDWEB-184 DEBUG       PDUDecoder CIR_QUERY_SCP(180) >> P-DATA_TF[len=346]
2017-10-11 08:39:27,634 RESMDWEB-184 DEBUG       PDUDecoder CIR_QUERY_SCP(180) >> PDV[len = 342, pcid = 5, mch = 2]
2017-10-11 08:39:27,634 RESMDWEB-184 DEBUG       PDUDecoder Dataset:
>(0008,0020) DA #8 [20171010] Study Date
>(0008,0030) TM #6 [081750] Study Time
>(0008,0050) SH #8 [7982604] Accession Number
>(0008,0052) CS #6 [STUDY] Query/Retrieve Level
>(0008,0054) AE #14 [Test-AE] Retrieve AE Title
>(0008,0056) CS #6 [ONLINE] Instance Availability
>(0008,0061) CS #2 [US] Modalities in Study
>(0008,0090) PN #16 [Test-RP] Referring Physician’s Name
>(0008,1030) LO #32 [US EXTREMEITY NON VASCULAR LEFT] Study Description
>(0010,0010) PN #12 [Test-P] Patient’s Name
>(0010,0020) LO #8 [0904687] Patient ID
>(0010,0021) LO #4 [EST] Issuer of Patient ID
>(0010,0030) DA #8 [19600819] Patient’s Birth Date
>(0010,0040) CS #2 [F] Patient’s Sex
>(0020,000D) UI #52 [1.2.840.113619.2.182.12076797980.1507648569.8921324] Study Instance UID
>(0020,0010) SH #8 [7982604] Study ID
>(0020,1206) IS #2 [1] Number of Study Related Series
>(0020,1208) IS #2 [13] Number of Study Related Instances

 

Tail Pureweb Log

1- Start two SSH clients and connect to the server
2- In one SSH client, Tail the pureweb.log file by running the following command:

tail -f pureweb.log > x.log

   where (x) is the CSI case number.

Tcpdump

1. Start another SSH clients and connect to the server

2. in the second SSH client, start a tcpdump by running the following command:

tcpdump -i eth0 -s 0 -w <x.pcap>

  where (x) is the CSI case number