Log Configuration

You can control the amount of detail written to the LLS log files, and the size at which they rotate, by editing the config.json file.

About this task

Configuring the log settings is optional. The default settings are suitable for normal operation, and you usually change them only when more detail is needed to investigate a problem.

The log section of config.json contains three settings:

"log": {
    "log_level": 1,
    "disabled": false,
    "max_log_size_mb": 4
}
Setting Description
log_level The lowest level of message written to the log file. The default is 1 (Info).
disabled Set to true to stop writing log files. The default is false.
max_log_size_mb The size in MB at which a log file rotates. The default is 4.

Procedure

  1. Go to the directory where the config.json file is located.

    After installation, config.json is in the installation directory.

  2. Locate the log section and set log_level to the required value.
    Value Level Description
    -1 Trace Very detailed debugging information
    0 Debug Detailed debugging information
    1 Info Informational messages (default)
    2 Warn Potential issues
    3 Error Application errors
    4 Fatal Severe errors
    5 Panic System halted

    Only messages at or above the configured level are written to the log file. For example, at level 3 only Error, Fatal, and Panic messages appear.

  3. Save the file after making the changes.
  4. Restart the LLS service.

    For the restart commands, see TLS Security Configuration.

Results

The new log settings take effect when the service restarts. The log files are written to the logs folder in the installation directory. See Troubleshooting HCL Local License Server.