uCosminexus Application Server, Application Setup Guide

[Contents][Index][Back][Next]

3.4 Settings for log acquisition of server management commands

You can change the log output destination and log level for the logs of server management commands. The items that you can change, and the user-defined files and keys corresponding to the items are as follows:

Item Corresponding user-defined file and key
Log output destination -Dejbserver.log.directory option of the USRCONF_JVM_ARGS key of usrconf.bat (in Windows) or usrconf (in UNIX)
Log level ejbserver.logger.enabled.* key of usrconf.properties

For details on the files and keys, see 5. Files Used with Server Management Commands in the uCosminexus Application Server Definition Reference Guide.

Note
The disk space required for the log output directory of the server management commands varies according to the value specified in the ejbserver.cui.logfile.compatible key.

When the specification value is true
51,655KB + trace information of TPBroker

When the specification value is false
18,624KB + trace information of TPBroker

For details on the disk space required to output the trace information of TPBroker, see the description related to the occupied disk space in the TPBroker Operation Guide.

Organization of this section
(1) Changing the log output destination
(2) Changing the log level

(1) Changing the log output destination

To change the log output destination of server management commands, specify the output-destination directory of logs in usrconf.bat (in Windows) or usrconf (in UNIX) for server management commands.

Changing the log output destination
The default log output destination is as follows:
  • In Windows
    Cosminexus-installation-directory\CC\admin\logs
  • In UNIX
    /opt/Cosminexus/CC/admin/logs/
You can change the output destination for the logs of server management commands with the -Dejbserver.log.directory option of the USRCONF_JVM_ARGS key of usrconf.bat (in Windows) or usrconf (in UNIX).
Setting example
  • In Windows
    set USRCONF_JVM_ARGS="-Dejbserver.log.directory=C:\CClogs\admin"
  • In UNIX
    set USRCONF_JVM_ARGS="-Dejbserver.log.directory=/CClogs/admin"

Current directory
The current directory when the log output destination is specified by a relative path is the current directory when a server management command is executed.
For example, when the user ID is user1 and the home directory of the user is C:\Documents and Settings\user1, and you log in with this user ID, the current directory immediately after login becomes C:\Documents and Settings\user1. Here, if you execute a server management command, the current directory becomes C:\Documents and Settings\user1.
Note
  • When you change the output destination of logs, create the output-destination directory for the logs after the change before starting the J2EE server.
    If the output-destination directory for the logs after the change does not exist, messages KDJE37209-E, KDJE37210-E, and KDJE37211-E are output during the execution of the server management commands, resulting in an abnormal termination.
  • When multiple J2EE servers are running on the same host, specify the settings to have a unique directory name on each server, such as including the server name in the directory, so that the log output destination is not the same directory. Note that when the same directory is specified in the key value, the operation is not guaranteed.
  • When you change the output destination of logs and output the logs in a directory other than the work directory, the log file is not deleted during the un-setup of the server. If you want to delete the log file, you may do so manually.
  • Even when you set up the output destination for logs of the maintenance information and garbage collection of JavaVM in a user-defined file, the value specified in add.jvm.arg=-XX:HitachiJavaLog:log-output-destination of usrconf.cfg is given priority. Take note when setting the output destination for the logs of the maintenance information and garbage collection of JavaVM.
  • When you perform operations with the Management Server remote management function, you cannot change the log output destination of server management commands.

(2) Changing the log level

The log level of server management commands represents the importance of logs. There are four log levels; Error, Warning, Information, and Debug. If you set a log level, the log of the set level is output. By default, only the log of the Error level is acquired. In normal cases, use the default settings.

A log level is set by the following key of usrconf.properties for the server management commands:

ejbserver.logger.enabled.*=level-name

In the level name, specify either one or multiple character strings from Error, Warning, Information, and Debug. To specify multiple levels, demarcate the character strings of the level name with a comma (,).

Coding examples:
  1. ejbserver.logger.enabled.*=Error
  2. ejbserver.logger.enabled.*=Error,Warning
  3. ejbserver.logger.enabled.*=Error,Warning,Information
  4. ejbserver.logger.enabled.*=Error,Warning,Information,Debug
 
Note
  • The number of logs that can be acquired increases in the order of 1, 2, 3, and 4 of the coding examples. If you set multiple log levels and acquire the logs, performance deteriorates, and switching of the number of log files occurs frequently.
  • When you specify a character string other than Error, Warning, Information, or Debug in the level name, or when you specify a blank value, the KDJE90009-W message is output. The log of the Error level is acquired.