Diagnosing problems with message logs
WebSphere® Application Server can write system messages to several general purpose logs, including JVM, process, and IBM® service logs, which can be examined for problem determination.
Before you begin
The JVM logs are created by redirecting the System.out and System.err streams of the JVM to independent log files. WebSphere Application Server writes formatted messages to the System.out stream. In addition, applications and other code can write to these streams using the print() and println() methods defined by the streams. Some Developer Kit built-ins such as the printStackTrace() method on the Throwable class can also write to these streams. Typically, the System.out log is used to monitor the health of the running application server. The System.out log and System.err log can be used for problem determination. The System.err log contains exception stack trace information that is useful when performing problem analysis.
- install_root/profiles/profile_name/logs/server_name
- profile_root/logs/server_name
In the case of a WebSphere Application Server Network Deployment configuration, JVM logs are also created for the deployment manager and each administrative agent because they also represent JVMs.
There is one set of STDOUT and STDERR log streams for each application server and all of its applications. JVM logs are also created for the deployment manager and each administrative agent because they also represent JVMs.
The process logs are created by redirecting the STDOUT and STDERR streams of the process to independent log files. Native code, including the Java™ virtual machine (JVM) itself, writes to these files. As a general rule, WebSphere Application Server does not write to these files. However, these logs can contain information relating to problems in native code or diagnostic information written by the JVM.
As with JVM logs, there is a set of process logs for each application server, since each JVM is an operating system process. For WebSphere Application Server Network Deployment configuration, a set of process logs is created for the deployment manager and each administrative agent.
In addition to these general purpose logs, WebSphere Application Server contains other specialized logs that are specific to a particular component or activity. For example, the HTTP server plug-in maintains a special log. Normally, these logs are not of interest, but you might be instructed to examine one or more of these logs while performing specific problem determination procedures. For details on how and when to view the plug-in log, see the Accessing a web resource through the application server and bypassing the HTTP server subsection of the A web resource does not display topic.
About this task
Procedure
Example
How to direct SYSPRINT and SYSOUT output to an HFS file.
If you are familiar with UNIX or Windows environments, you might be reluctant to use the facilities of SDSF (or IOF) to view the SYSPRINT and SYSOUT output from servants. If you would rather use a familiar editor (such as vi) in a Telnet session to view your output, it is possible to redirect the SYSPRINT and SYSOUT outputs to files in an HFS.
You can use the redirect_server_output_dir WebSphere environment variable to redirect server logs to a file system. This property can be specified at the cell, node, or server level. The server name and time stamp information is added automatically to the file names. For more information on redirecting server logs, see the Output destinations topic.