IBM Support

How to enable a JDBC trace for toolbox driver

Troubleshooting


Problem

This document describes how to set a JDBC™ trace for the AS/400® database driver, jt400 also known as the toolbox driver. This is from IBM® Technical Document entitled: "Enabling Java™ Toolbox and JDBC Tracing with an External Trace Property"

Resolving The Problem

Here are the instructions to enable the jt400 trace on the IBM® WebSphere® Application Server.

Add the custom following properties to the JDBC DataSource. 

Parameter nameParameter value
tracetrue
toolboxTraceall

For more information on the parameters that may be specified for the jt400 data source, see the JDBC Trace Instructions in the document, The All-In-One Toolbox JDBC Tracing Guide
(We need to have the trace taken for all categories.  This will include the data  stream.)  

Alternatively, you can enable the trace using a jvm -D parameters. See the Java Virtual Machine (JVM) Properties in The All-In-One Toolbox JDBC Tracing Guide. To set the parameters, use the following instructions.

Using the administrative console
    1. Start the administrative console.
    2. Select Servers > Application Servers > server_name.
    3. Under Server Infrastructure, expand Java and Process Management and click Process Definition.
    4. Under Additional properties, click Java Virtual Machine.
    5. In the Generic JVM™ arguments field, enter
     -Dcom.ibm.as400.access.Trace.file=C:\temp\trace.out
    and
    -Dcom.ibm.as400.access.Trace.category=all
    6. Click Apply and Save.
    7. Stop and restart the server.

Modifying the server.xml file for the profile
    1. Make a backup copy of the server.xml file before modifying the file.
    2. Find genericJvmArguments= in the file. In the quoted phrase, insert :-Dcom.ibm.as400.access.Trace.file=C:\temp\trace.out
    For example:
    genericJvmArguments="-Dcom.ibm.as400.access.Trace.file=C:\temp\trace.out"
    3. Save the changes.
    4. Stop and restart the server.


To control where the trace is written set these settings in the Generic JVM arguments of the Application Server.
-Dcom.ibm.as400.access.Trace.file=C:\temp\trace.out  



For more information on these properties, you may also refer to, jt400 System Properties document.



[{"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"DB Connections\/Connection Pooling","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF012","label":"IBM i"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"9.0;8.5.5;8.0;7.0","Edition":"Base;Network Deployment","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Java SDK","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
15 June 2018

UID

swg21318451