Logging and Debugging Options within OC4J

In this section we'll cover the logging and debugging options within OC4J.

Logging

The OC4J server is based on the Orion web application server. Therefore, the logging and debugging features within Orion are also within OC4J (although Oracle may make some changes). There are six log file types that can be found within OC4J: application, global application, server, HTTP web access, RMI, and JMS.

Application Log

Each deployed application generates an application.log located in $ORACLE_HOME/j2ee/home/application-deployments/ application_name . This log file shows application deployments, stopping, starting, and any errors with timestamps that occurred within the application. This is specific to a deployed application.

Global Application Log

The server tracks startup and shutdown errors in the global-application.log located in the $ORACLE_HOME/j2ee/home/log directory.

Server Log

The server.log file shows startup, shutdown, and internal errors with timestamps within the OC4J container. It's located in the $ORACLE_HOME/j2ee/home/log directory.

HTTP Web Access Log

The HTTP web access log shows Apache style access to the application as shown in http-web-access.log , as follows :

 192.168.1.39 - - [27/May/2004:19:36:14 -0500] "GET / HTTP/1.1" 200 2919 192.168.1.39 - - [27/May/2004:19:36:14 -0500] "GET /blaf.css HTTP/1.1" 200 5832 192.168.1.39 - - [27/May/2004:19:36:34 -0500] "GET /examples/servlets HTTP/1.1" 301 0 

You can use this file to see what traffic is reaching your server, from where, and what it is doing. This file is located in $ORACLE_HOME/j2ee/home/log . The format and location of this log file is configured within $ORACLE_HOME/j2ee/home/config/http-web-site.xml .

RMI Log

Remote Method Invocation (RMI) messages are written to rmi.log , which is located in the $ORACLE_HOME/j2ee/home/log directory.

JMS Log

Java Message Service (JMS) messages are written to jms.log , which is located in the $ORACLE_HOME/j2ee/home/log directory.

Debug Switches

It's possible to pass debug switches to OC4J, both with the OC4J standalone and as part of a 10g AS mid- tier installation. To set a switch within the 10g AS mid-tier server, put it in the Java Options box of the ASC Server Properties page, as shown in Figure D-2.

To run the OC4J standalone with a debug switch, you need to adjust your startup command. Place - Dswitch_name after the java command when starting OC4J. For example, to start up OC4J with the http.error.debug option on, issue the following:

 $ java -Dhttp.error.debug -jar oc4j.jar -config config/server.xml -verbosity 10 

Here are some multiple debug switches that are available.

  • ApplicationServerDebug

  • jdbc.debug

  • jdbc.connection.debug

  • datasource.verbose

  • DataSourceConnection.debug

  • rmi.debug

  • http.error.debug

  • http.session.debug

  • ajp.debug

  • ejb.debug.state

  • tag.library.loadgin.debug

  • debug.corruptbinary

  • multicast.debug

  • zip.debug

Other debug switches are also available. For more information see Appendix A of the OTN at http://download-west.oracle.com/docs/cd/B12314_01/web.904/b10323/toc.htm as well as the Orion application server website ( www.ironflare.com ). Go to Documentation and then Debugging.



Oracle Application Server 10g. J2EE Deployment and Administration
Oracle Application Server 10g: J2EE Deployment and Administration
ISBN: 1590592352
EAN: 2147483647
Year: 2004
Pages: 150

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net