Collecting a Managed File Transfer standalone logger trace dynamically

The fteSetLoggerTraceLevel command allows trace to be collected from a running logger. This can be very useful if IBM Support need to see a trace from a logger that cannot be stopped.


To collect a trace from a logger using the fteSetLoggerTraceLevel command, complete the following steps.


Procedure

  1. Turn on trace for the logger by running the following command:
    fteSetLoggerTraceLevel -traceLogger classes=level logger_name

    The -traceLogger parameter determines the internal classes and packages that are to be traced. Unless otherwise specified by the IBM Support representative, set this property to the value com.ibm.wmqfte=all.

  2. Reproduce the issue.
  3. Turn trace off, using the command:
    fteSetLoggerTraceLevel -traceLogger =off logger_name
  4. If a logger is busy, then it is possible that the trace files will wrap quickly and overwrite the information needed to investigate the issue. In this situation there are two options:
    1. The first option is to:
      1. Schedule some time to stop the logger.
      2. Locate the logger.properties file for the logger that needs to be traced. The logger.properties file can be found in the MQ_DATA_PATH/mqft/config/coordination_qmgr_name/loggers/logger_name directory.
      3. Edit the file and add entries for the following properties:

        • traceFiles=number of trace files to use
        • traceSize=size of each trace file, in MB

          The traceFiles and traceSize properties are used to control the amount of trace data that is collected.

          The default value of the traceFiles property is 5, and the traceSize property has the default value of 20MB. This means that if you turn on trace dynamically, and you have not set the properties, the agent writes trace information to 5 wrapping trace files, each with a maximum size of 20MB.

          We should set these properties to large values, to collect as much trace data as possible.

          For example, to collect 1GB of wrapping trace, add the following lines to the logger.properties file:
          traceFiles=5
          traceSize=200
          
          This results in the logger writing trace data to a maximum of 5 files, where each file has a size of 200MB.

          For more information on these logger properties, see The MFT logger.properties file.

      4. Stop the logger, using the fteStopLogger command.
      5. Start the logger, by running the fteStartLogger command.
      6. Run the command:
        fteSetLoggerTraceLevel -traceLogger classes=level logger_name 
        to enable trace for the logger.

        Unless otherwise specified by the IBM Support representative, set the -traceLogger property to the value com.ibm.wmqfte=all.

      7. Reproduce the issue.
      8. Turn trace off on the logger by running the command:
        fteSetLoggerTraceLevel -traceLogger =off logger_name

    2. The second option is to contact the IBM Support representative, if it is not possible to stop the logger for a short period of time. We can then discuss alternative trace specifications to use, in order to reduce the amount of trace data that is being generated.


Results

The resultant trace files are written to the MQ_DATA_PATH/mqft/logs/coordination_qmgr_name/loggers/logger_name/logs/trace%PID% directory, where %PID% is the process identifier for the logger. Parent topic: Tracing Managed File Transfer standalone loggers on Multiplatforms