Skip to main content

Change Log Levels in OPNBI Application

An application log is a file that contains information about events that have occurred within a software application. These events are logged out by the application and written to the file. They can include errors and warnings as well as informational events.

Here are some common components that you will generally find in application log messages:

Context information: Background information that provides insight into the state of the application at the time of the message.

Timestamps: A specific piece of contextual information for tracking and correlating issues.

Log levels: Labels that help you calculate the level of importance for the entries in your log file. Frequently used levels include INFO, WARN, and ERROR.

Prerequisites

warning

Please take backup of log4j.properties file before making any changes. you will find log4j.properties file at (your_directory)/OPNBI/tomcat/webapps/opnbi/WEB-INF/classes folder

  • log4j.properties file. you will find log4j.properties file at (your_directory)/OPNBI/tomcat/webapps/opnbi/WEB-INF/classes folder

Reference

Change log levels

Follow these steps to know how to change log levels in OPNBI Appplication;

  1. Open log4j.properties file in text editor from folder (your_directory)/OPNBI/tomcat/webapps/opnbi/WEB-INF/classes

  2. In this File you will see log properties for 6 categories listed as System Logger, DB Logger, Security Logger, All Other Log, Usage Log & Alert Log

  3. you will see in this file, by default log level is ERROR for all log categories except Usage Log. Usage log is OFF by default.

System LoggerDB Logger
Docusaurus Slash IntroductionDocusaurus Slash Introduction
Security LoggerAll Other Log
Docusaurus Slash IntroductionDocusaurus Slash Introduction
Security Logger
Docusaurus Slash Introduction
  1. Change log level in all categories marked above and system will generate logs accordingly. for example provide log level ALL in place of ERROR and save this file

  2. Restart your tomcat server to make these changes reflect.