Message Types and Levels

8-4 Oracle Fusion Middleware Administrators Guide for Oracle Identity Manager

8.1.3 Configuring Log Handlers

Individual log handlers are configured in the log_handlers section of the logging.xml file. Configure the level attribute for the handler to set the amount of detail that the handler will accept from loggers. To configure the log handler-level attribute: 1. Open the DOMAIN_NAMEconfigfmwconfigserversSERVER_NAMElogging.xml file. 2. Change the level attribute as shown in the following examples. In this example XML code, the level attribute for the console-handler is set to WARNING:32. log_handler name=console-handler class=oracle.core.ojdl.logging.ConsoleHandler formatter=oracle.core.ojdl.weblogic.ConsoleFormatter level=WARNING:32 For the console-handler to be able to write TRACE level messages to the console, change the level attribute as shown: log_handler name=console-handler class=oracle.core.ojdl.logging.ConsoleHandler formatter=oracle.core.ojdl.weblogic.ConsoleFormatter level=TRACE:1 3. Save your changes and restart the application server.

8.1.3.1 Log Handler Configuration Tools

Log handlers that write to a file have additional properties that can be configured. For example, this excerpt from logging.xml configures the odl-handler: log_handler name=odl-handler class=oracle.core.ojdl.logging.ODLHandlerFactory filter=oracle.dfw.incident.IncidentDetectionLogFilter property name=path value={domain.home}servers{weblogic.Name}logs{weblogic.Name}-diagnostic.lo g property name=maxFileSize value=10485760 property name=maxLogSize value=104857600 property name=encoding value=UTF-8 property name=useThreadName value=true property name=supplementalAttributes value=J2EE_APP.name,J2EE_MODULE.name, WEBSERVICE.name,WEBSERVICE_PORT.name,composite_instance_id,component_instance_id, composite_name,component_name log_handler Note: If you are not getting the volume of output that you expect in a log, then verify that the level attribute for both the logger and the log handler are set appropriately. For example, if the logger is set to TRACE and the log handler is set to WARN, then the handler does not generate messages more detailed than WARN. Note: You must have a basic understanding of XML syntax before you attempt to modify the logging.xml file. Enabling System Logging 8-5 To make changes to log handler properties, you can use either the Fusion Middleware Control tool or the WLST command-line tool.

8.1.4 Configuring Loggers

Individual loggers are configured in the loggers section of the logging.xml file. More than twenty different Oracle Identity Manager loggers that can be configured to send messages to log handlers. Oracle Identity Manager loggers are described in Table 2 on page 7. Setting the level attribute for the logger configures the amount of detail and, hence, the volume of messages that the logger sends to its handlers. Nesting one or more handler elements inside of logger elements assigns handlers to loggers. The following excerpt shows a logger called OIMCP.PSFTCOMMON. The level attribute is set to WARNING:32 and the logger sends messages to three handlers: logger name=OIMCP.PSFTCOMMON level=WARNING:32 useParentHandlers=false handler name=odl-handler handler name=wls-domain handler name=console-handler logger A logger can inherit a parent loggers settings, including the parents level setting and other attributes, as well as the parent loggers handlers. To disable inheritance, set the useParentHandlers attribute to false, as shown in the previous excerpt. At the top of the logger inheritance tree is the root logger. The root logger is the logger with an empty name attribute, as shown in the following example. loggers logger name= level=WARNING:1 handler name=odl-handler handler name=wls-domain handler name=console-handler logger -- Additional loggers listed here -- loggers If a logger is configured with only its name attribute, the logger will inherit the rest of its attributes from the root logger, as shown in the following example: loggers logger name=oracle.iam.identity.rolemgmt -- Additional loggers listed here -- loggers To configure loggers: See Also: ■ Configuring Settings for Log Files in the Oracle Fusion Middleware Administrators Guide for information about both the Fusion Middleware Control tool and the WLST command-line tool ■ Logging Custom WLST Commands in the Oracle Fusion Middleware WebLogic Scripting Tool Command Reference for information about the WLST command-line tool