InfoCenter Home >
6: Administer applications >
6.6: Tools and resources quick reference >
6.6.28: Planning and skills for IBM Distributed Debugger and OLT >
6.6.28.2: Using Debugger and OLT

6.6.28.2: Using Debugger and OLT

This article provides instructions for using IBM Distributed Debugger and Object Level Trace (OLT) in a WebSphere Application Server environment.

Before you trace or debug

When compiling code, be sure to include debugging information by using the -g command line argument. For example:

javac -g myClass.java

Procedural overview

Here is an overview of the procedure for using tracing and debugging, with steps that link to detailed instructions below:

  1. Configure the application server Debug properties

  2. Start the application server

  3. Optionally, minimize the WebSphere Administrative Console

  4. Start the Web server

  5. Start the OLT or Debugger/OLT client and adjust settings

    For a JSP .91 file, copy the file to Web server HTML directory

  6. Access the application or Java component that you are tracing or debugging

  7. Trace or debug the code in the Debugger/OLT

 

To reiterate, the steps must be performed in order. Specifically:

  1. Configure an application server's debugging properties and start it

  2. Start the OLT executable on the machine where you want to view OLT, debug output

  3. Request a resource or application deployed in the application server

Detailed steps

Each step in the procedure is now discussed in detail.

Step Description
1: Configure the application server Debug properties

To trace or debug code running on an application server, you must enable tracing or debugging on the server. The OLT and debug enabled buttons are on the Debug tab.

  1. Click the Topology tab to display the Topology tree.

  2. Click the application server whose OLT tracing and debugging settings you want to specify. The server properties are displayed on the right side of the console.

  3. Configure the application server:

    • To enable tracing, select the Object Level Tracing enabled check box.

    • To enable debugging, select the Object Level Tracing enabled and Debug enabled check boxes.

  4. Save the property changes.

Now you will be able to trace or debug all servlets and JavaServer Pages (JSP) files deployed in the application server, according to the application server Debug properties you specified.

2: Start the application server

  1. Display the Topology tree view.

  2. Expand the tree to locate the application server on which to perform tracing or debugging.

  3. Right-click the server and click Start.

3: Optionally, minimize the WebSphere Administrative Console

When finished configuring and starting the application servers in the WebSphere Administrative Console, you can minimize the console because the rest of the tracing or debugging procedure is conducted outside of the console.

4: Start the Web server

Tracing and debugging in the Debugger and OLT client interfaces begin when the Java component being traced is accessed by a user at a Web browser. Your Web server must be started in order for this to work correctly.

5: Start the Debugger/OLT client and adjust settings

To start the client interface:

  1. Open a system command window.

  2. Issue the command:

    olt

Ensure that the default execution mode is set to trace and debug in the Client Controller. Set the checkbox to use the default settings.

6: Access the application or Java component that you are tracing or debugging

Make a request for Java component or application that you are tracing or debugging, as though you are a typical user. Information is sent to the Debugger/OLT.

7: Trace or debug the code in the Debugger/OLT client interfaces

When the Debugger/OLT clients are first displayed, you are prompted to provide the location of the source code for the Java component or application you are tracing or debugging. After you supply the information, you can start tracing or debugging the code in the Debugger/OLT clients.

Examples of debugging local applications

Debugging the Snoop servlet -- local Debugger/OLT client

  1. Configure the application server containing Snoop servlet for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Debug enabled and Object Level Trace enabled check boxes.

    3. Click Apply.

  2. Start the application server:

    1. In the Topology tree, make sure the Default Server (or other application server you are using) is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the debugging interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command:

      olt

      This starts the OLT daemon, which listens on a port and displays the debugger interface when a request arrives.

      Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  6. In a Web browser, request the Snoop servlet:

    http://localhost/servlet/snoop
  7. Use the Debugger/OLT:

    1. Watch for the Debugger/OLT. The debugger interface is displayed in response to your requesting a servlet running on an application server (default server) for which debugging is enabled.

      When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      The debugger will find source files that are in the classpath of the JVM running the code being debugged. It does not find a source file, it will prompt you for the location of the file, HttpServlet.java in this case.

      HttpServlet is the parent class of the Snoop servlet, and is the class in which the service() method is implemented. Starting with the requested servlet, the debugger will look for the first service() method implementation it can find. Because Snoop does not implement service(), the debugger looked in Snoop's parent class, HttpServlet.

    2. When prompted for the source path, browse <server root>/hosts/default_host/default_app/servlets.

    3. Watch the Debugger/OLT, which should stop in the service() method. To step into the Snoop servlet, perform a series of step overs until you get to the doGet() method call. Do a step into on this method to reach Snoop.

    4. Watch for the debugger to break in the service method of the Snoop servlet. You can step debug, or simply click Run to complete the request.

Debugging very_simple.jsp (JSP .91) -- local OLT client

  1. Configure the application server containing the JSP file for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Debug enabled and Object Level Trace enabled check boxes.

    3. Click Apply.

  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the debugging interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command:

      olt

    This starts the OLT daemon, which listens on a port and displays the debugger interface when a request arrives.

    Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  6. Copy the file <install_root>/hosts/default_host/default_app/web/very_simple.jsp to the document root of the Web server.

  7. In a Web browser, request the very_simple JavaServer Pages (JSP) file:

    http://localhost/very_simple.jsp
  8. Use the Debugger/OLT:

    1. Watch for the Debugger/OLT.

      When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      You will likely be prompted for the location of the source file pagecompile/_very_simple_xjsp.java.

    2. Browse for and select the file, which is located in the directory <install_root>/hosts/default_host/default_app/web/very_simple_jsp.java

    3. Watch for the debugger to break in the service method of the very_simple.jsp. You can step debug, or simply click Run to complete the request.

Debugging very_simple.jsp (JSP 1.0) -- local OLT client

  1. Configure the application server containing the JSP file for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Debug enabled and Object Level Trace enabled check boxes.

    3. Click Apply.

  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the debugging interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command:

      olt

      This starts the OLT daemon, which listens on a port and displays the debugger interface when a request arrives.

      Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  6. Copy the file <install_root>/hosts/default_host/default_app/web/very_simple.jsp to the document root of the Web server.

  7. In a Web browser, request the very_simple JavaServer Pages (JSP) file:

    http://localhost/very_simple.jsp
  8. Use the Debugger/OLT:

    1. Watch for the Debugger/OLT.

      When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      You will likely be prompted for the location of the source file pagecompile/_very_simple_xjsp.java.

    2. Browse for and select the file, which is located in the directory <install_root>/hosts/default_host/default_app/pagecompile/_very_simple_xjsp.java

    3. Watch for the debugger to break in the service method of the very_simple.jsp. You can step debug, or simply click Run to complete the request.

Debugging the Hello enterprise bean -- local OLT client

  1. Configure the application server containing the enterprise bean for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Debug enabled and Object Level Trace enabled check boxes.

    3. Save the properties.

  2. If you have not already done so, install and deploy the Hello enterprise bean:

    1. In the Topology tree, find and right-click the Default Container in the Default Server.

    2. In the resulting menu, click Create -> Enterprise Bean.

    3. In the resulting window, click Browse.

    4. In the Browse dialog, browse for <install_root>/deployableEJBs/Hello.jar. Double-click it to display its deployment descriptor. Click the deployment descriptor and exit the Browse dialog.

    5. Back in the dialog window for creating an enterprise bean, click Create.

    6. When the deployment process is complete, verify that the Hello enterprise bean now is displayed in the Default Container on the Topology tree.

  3. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command:

      olt

    3. This starts the OLT daemon, which listens on a port and displays the debugger interface when a request arrives.

      Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  6. Run the Hello sample. On Windows NT, click Start -> Programs -> IBM WebSphere -> Application Server version 3.x.0 -> Samples, then select the Hello enterprise bean.

  7. Use the Debugger/OLT:

    1. Watch for the Debugger/OLT.

      When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      You will likely be prompted for the location of the source file _WebSphereSamples/_EJBs/_HelloEJB/_HelloEJB_jsp.

    2. Browse for and select the file, which is located in the directory <install_root>/WebSphereSamples/EJBs/HelloEJB/HelloEJB.jsp

    3. Watch for the debugger to break in the service method of the HelloEJB.jsp. You can step debug, or simply click Run to complete the request.

Examples of tracing local applications

Tracing the Snoop servlet -- local Debugger/OLT client

  1. Configure the application server containing Snoop servlet for tracing:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Click Apply.

  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the Debugger/OLT:

      olt

      This starts the Debugger/OLT, which will display the trace information generated by the objects that service your request.

  6. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  7. In a Web browser, request the Snoop servlet:

    http://localhost/servlet/snoop
  8. Watch the Debugger/OLT for a line representing Snoop servlet. It will be labeled HttpServlet because that is the class that implements the service method. (HttpServlet is the parent class of Snoop servlet). On the line, you should see circles that represent the beginning and end of the service method.

Tracing very_simple.jsp (JSP .91) -- local Debugger/OLT client

  1. Configure the application server containing the JSP file for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Click Apply.

  2. Start the application server:
    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the debugger daemon:

      olt

  6. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  7. Copy the file <install_root>/hosts/default_host/default_app/web/very_simple.jsp to the document root of your Web server.

  8. In a Web browser, request the very_simple JSP file:

    http://localhost/very_simple.jsp
  9. Watch the Debugger/OLT for a line representing very_simple.jsp. On the line, you should see circles that represent the beginning and end of the service method.

Tracing very_simple.jsp (JSP 1.0) -- local Debugger/OLT client

  1. Configure the application server containing the JSP file for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Click Apply.

  2. Start the application server:

      In the Topology tree, make sure the Default Server is selected.

    1. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the debugger daemon:

      olt

  6. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  7. Copy the file <install_root>/hosts/default_host/default_app/web/very_simple.jsp to the document root of your Web server.

  8. In a Web browser, request the very_simple JSP file:

    http://localhost/admin/very_simple.jsp
  9. Watch the Debugger/OLT for a line representing very_simple.jsp. On the line, you should see circles that represent the beginning and end of the service method.

Tracing the Hello enterprise bean sample -- local Debugger/OLT client

  1. Configure the application server containing the enterprise bean for tracing:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Click Apply.

  2. If you have not already, install and deploy the Hello enterprise bean:

    1. In the Topology tree, find and right-click the Default Container in the Default Server.

    2. In the resulting menu, click Create -> Enterprise Bean.

    3. In the resulting window, click Browse.

    4. In the Browse dialog, browse for <install_root>/deployableEJBs/Hello.jar. Double-click it to display its deployment descriptor. Click the deployment descriptor and exit the Browse dialog.

    5. Back in the dialog window for creating an enterprise bean, click Create.

    6. When the deployment process is complete, verify that the Hello enterprise bean now is displayed in the Default Container on the Topology tree.

  3. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  4. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  5. Make sure your Web server is started.

  6. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the debugger daemon:

      olt

  7. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  8. Run the Hello sample. On Windows NT, click Start -> Programs -> IBM WebSphere -> Application Server version 3.x.0 -> Samples, then select the Hello enterprise bean.

  9. Watch the Debugger/OLT for lines representing the HelloEJB JSP file and the Hello enterprise bean itself.

Examples of debugging remote applications

Debugging snoop servlet from a remote machine

  1. Configure the application server containing the servlet for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed in the right side of the console.

    2. For the default server's debugging properties, select Debug enabled and OLT enabled check boxes.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.

  2. Start the application server.

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Make sure your Web server is started.

  4. Start the Debugger/OLT:

    1. Open a system command window on the remote machine.

    2. Issue the command to start the debugger daemon:

      olt

      This starts the OLT daemon, which listens on a port and displays the debug user interface when a request arrives.

  5. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  6. In a Web browser, request the Snoop servlet:

    http://your.server.name/servlet/snoop
  7. Use the Debugger/OLT:

    1. Watch for the Debugger/OLT. When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      The debugger interface is displayed in response to your requesting a servlet running on an application server (default server) for which debugging is enabled.

      The debugger will find source files that are in the classpath of the JVM running the code being debugged. It does not find a source file, it will prompt you for the location of the file, HttpServlet.java in this case.

      HttpServlet is the parent class of the Snoop servlet, and is the class in which the service() method is implemented. Starting with the requested servlet, the debugger will look for the first service() method implementation it can find. Because Snoop does not implement service(), the debugger looked in Snoop's parent class, HttpServlet.

    2. Browse for and select HttpServlet, which is located in the directory <install_root>/classes/com/javax/http

    3. Watch the Debugger/OLT, which should stop in the service() method. To step into the Snoop servlet, perform a series of step overs until you get to the doGet() method call. Do a step into on this method to reach Snoop.

    4. Watch for the debugger to break in the service method of the Snoop servlet. You can step debug, or simply click Run to complete the request.

Debugging very_simple.jsp (JSP .91) from a remote machine

  1. Configure the application server containing the JSP page for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.

  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start Task toolbar button or use the Start option on the server's right-click menu.

  3. Make sure your Web server is started.

  4. Start the Debugger/OLT:

    1. Open a command window on the remote machine.

    2. Run the following command to start the OLT daemon:

      olt

      This starts the OLT daemon, which listens on a port and displays the debugger interface when a request arrives.

  5. Adjust the Debugger/OLT settings. Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.
  6. Copy the file install_root\hosts\default_host\default_app\web\very_simple.jsp to the document root of your Web server.

  7. In a Web browser, request the very_simple JSP file:

    http://your.server.name/very_simple.jsp.
  8. Use the Debugger/OLT:

    1. When the Debugger/OLT interface is displayed, make sure that Options -> Step by Step debugging mode is set.
    2. You will likely be prompted for the location of the source file pagecompile\_very__simple.java.

    3. Browse for and select the file, which is located in the directory <install_root>\hosts\default_host\default_app\web\very__simple.jsp.

      You must install the source on the machine where you are running the debugger user interface.

    4. Watch for the debugger to break in the service method of the very_simple.jsp. You can step debug, or simply click Run to complete the request.

Debugging very_simple.jsp (JSP 1.0) from a remote machine

  1. Configure the application server containing the JSP page:

    1. In the Topology tree, locate the click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Debug enabled and OLT enabled check boxes.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.
  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start Task toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the debugging interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a command window on the remote machine.

    2. Run the following command to start the OLT daemon:

      olt

      This starts the OLT daemon, which listens on a port and displays the debugger user interface when a request arrives.

  6. Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.
  7. Copy the file <install_root>\hosts\default_host\default_app\web\very_simple.jsp to the document root of your Web server.

  8. In a Web browser, request the JSP page:

    http://your.server.name/very_simple.jsp
  9. Use the Debugger/OLT:

    1. Watch for the Debugger/OLT.

      When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      You will likely be prompted for the location of the source pagecompile\_very__simple_jsp_1. You must install the source on the machine where you are running the debugger user interface.

    2. Browse for and select the file, which is located in the directory <install_root>\temp\default_host\default_app\pagecompile\_very__simple_xjsp.java.

    3. Watch for the debugger to break in the service method of the very_simple.jsp. You can step debug, or simply click Run to complete the request.

Debugging the Hello enterprise bean sample from a remote machine

  1. Configure the application server containing the enterprise bean file:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the server's debugging properties, select the Debug enabled and Object Level Trace enabled check boxes.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.

     If you have not already done so, install and deploy the Hello enterprise bean:

    1. Select the Default Server.

    2. Select Default Container and right click.

    3. Select Create, Enterprise bean.

    4. In the window that appears, click browse. Go to AS_root\deployableEJBs\Hello.jar.

    5. Double click on the Hello.jar and select the deployment descriptor.

    6. Select Create to start the deployment process. An icon representing the Hello enterprise bean should appear in the Default Container.

  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the green Start Task toolbar button or use the Start option on the server's right-click menu.

  3. Make sure your Web server is started.

  4. Start the Debugger/OLT:

    1. Open a command window on the remote machine.

    2. Run the following command to start the OLT daemon:

      olt

      This starts the OLT daemon, which listens on a port and displays the debugger user interface when a request arrives.

      Ensure that the default execution mode is set to trace and debug in the Client Controller page. Set the check box to use the default settings.

  5. Run the enterprise bean sample. Use your Web browser to open:

    http://your.server.name/WebSphereSamples/index.html

    Click Enterprise beans, click Hello, and then run Hello.

  6. Use the debugger interface:

    1. Watch for the debugger interface.

      When the interface is displayed, make sure that Options -> Step by Step debugging mode is set.

      You will likely be prompted for the location of the source file. The debugger will automatically find and display any source that is in the classpath of the JVM being debugged. The debugger will prompt for any source that is not in the JVM classpath. The source for HelloEJB JSP is probably not in the classpath, so the debugger will prompt you for the location of the source _WebSphereSamples\_EJBs\_HelloEJB\_HelloEJB_jsp.

    2. Browse for and select the file, which is located in the directory <install_root>\WebSphereSamples\EJBs\HelloEJB\HelloEJB.jsp.

    3. The debugger should break in the service method of HelloEJB.jsp. You can step debug, or simply click Run to complete the request.

Examples of tracing remote applications

Trace Snoop servlet from a remote machine

  1. Configure the application server containing the servlet:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Debug enabled and Object Level Trace enabled check boxes.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.
  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the green Start Task toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but do not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a command window on the remote machine.

    2. Issue the command to start the OLT daemon:

      olt

      This starts the Debugger/OLT, which will display the trace information generated by the objects that service your request.

  6. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace only in the Client Controller page. Set the check box to use the default settings.

  7. In a Web browser, request the servlet:

    http://your.server.name/servlet/snoop
  8. Watch the Debugger/OLT for a line representing Snoop servlet. It will be labeled HttpServlet because that is the class that implements the service method. On the line, you should see circles on the line representing the beginning and end of the service method.

Trace very_simple.jsp (JSP .91) from a remote machine

  1. Configure the application server containing the JSP file for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.
  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the debugger daemon:

      olt

  6. Ensure that the default execution mode is set to trace only in the Client Controller page. Set the check box to use the default settings.
  7. Copy the file <install_root>\hosts\default_host\default_app\web\very_simple.jsp to the document root of your Web server.

  8. In a Web browser, request the JSP file:

    http://your.server.name/very_simple.jsp
  9. Watch the Debugger/OLT for a line representing very_simple.jsp. On the line, you should see circles representing the beginning and end of the service method.

Trace very_simple.jsp (JSP 1.0) from a remote machine

  1. Configure the application server containing the JSP file for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.
  2. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  3. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  4. Make sure your Web server is started.

  5. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the debugger daemon:

      olt

  6. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace only in the Client Controller page. Set the check box to use the default settings.
  7. Copy the file <install_root>\hosts\default_host\default_app\web\very_simple.jsp to the document root of your Web server.

  8. In a Web browser, request the JSP file:

    http://your.server.name/very_simple.jsp
  9. Watch the Debugger/OLT for a line representing very_simple.jsp. On the line, you should see circles representing the beginning and end of the service method.

Trace Hello enterprise bean WebSphereSample from a remote machine

  1. Configure the application server containing the enterprise bean for debugging:

    1. In the Topology tree, locate and click the Default Server, which is the default application server. Its properties will be displayed on the right side of the console.

    2. For the default server's debugging properties, select the Object Level Trace enabled check box.

    3. Set the OLT server host to the hostname of the remote machine on which OLT will be running.
    4. Click Apply.
  2. If you have not already, install and deploy the Hello enterprise bean:

    1. In the Topology tree, find and right-click the Default Container in the Default Server.

    2. In the resulting menu, click Create -> Enterprise Bean.

    3. In the resulting window, click Browse.

    4. In the Browse dialog, browse for <install_root>/deployableEJBs/Hello.jar. Double-click it to display its deployment descriptor. Click the deployment descriptor and exit the Browse dialog.

    5. Back in the dialog window for creating an enterprise bean, click Create.

    6. When the deployment process is complete, verify that the Hello enterprise bean now is displayed in the Default Container on the Topology tree.

  3. Start the application server:

    1. In the Topology tree, make sure the Default Server is selected.

    2. Start it. Either click the Start toolbar button or use the Start option on the server's right-click menu.

  4. Optionally, minimize (but not close) the WebSphere Administrative Console to allow more space on your desktop for the tracing interface.

  5. Make sure your Web server is started.

  6. Start the Debugger/OLT:

    1. Open a system command window.

    2. Issue the command to start the debugger daemon:

      olt

  7. Adjust the Debugger/OLT settings. When the interface is displayed, ensure that the default execution mode is set to trace only in the Client Controller page. Set the check box to use the default settings.
  8. Run the Hello sample. On Windows NT, click Start -> Programs -> IBM WebSphere -> Application Server version 3.x.0 -> Samples, then select the Hello enterprise bean.

  9. Watch the Debugger/OLT for lines representing the HelloEJB JSP file and the Hello enterprise bean itself.

Troubleshooting tips

See the prerequisites and limitations for known limitations, problems, and workarounds.

Go to previous article: Example: Installing OLT and Debugger clients on Windows NT Go to next article: Prerequisites and limitations of IBM Distributed Debugger and OLT

 

 
Go to previous article: Example: Installing OLT and Debugger clients on Windows NT Go to next article: Prerequisites and limitations of IBM Distributed Debugger and OLT