License logs
Logging can be enabled for the Four Js License Manager (FLM) and for any Genero license controller.
Requests sent by and responses received by the Four Js License Manager (FLM) or a Genero license controller can be recorded in log files. You can use these logs to troubleshoot licensing issues. Four Js may ask you to activate logging when providing support for a licensing problem.
By default, logging is disabled for the FLM and for a license controller. You enable logging by providing the appropriate entries in the FLM or license controller configuration file.
Logging the FLM
In addition to logging for the FLM, you can also log each license controller separately. Doing so will give you logs that are specific to a license controller, which may be useful when isolating issues during troubleshooting. You would complete the steps to enable logging for the FLM, then also complete the steps for logging each license controller.
Logging a license controller
If you are managing licenses with your local license controller (fglWrt or greWrt), you may want to enable logging for the local license controller.
Enable and configure logging in the license controller configuration file (fgllicense or grelicense). You can enable logs for output to file, syslog (Unix-like and macOS™ platforms only), and console, or any combination of those options.
; License configuration file
[log]
enabled=true
# To use the file logger
directory=${TEMP}
# Logged categories - values: error, info, warning, debug
# Debug category will produce an additional log file with .dlog extension.
categories="error,warning"
# Enable all log categories to troubleshoot licensing issues
# categories="all"
# To configure log rotation
maxfiles=5
maxsize="512M"
# To use the console logger
# console=true
# To use the syslog logger (Unix-like and macOS platforms only)
# syslog=true
# ...
where: - The
enabled
option enables logging. - The
categories
option specifies the type of events to record in the logs;error
,warning
,info
, anddebug
. Thedebug
category will produce an additional log file with the extension .dlog. The pseudo log categoryall
enables all log categories. This category should only be used when you have a licensing issue that needs to be investigated further, as it will create the most amount of logs. - The
directory
option specifies the directory where logs are stored. - The
maxfiles
option specifies the number of log files to keep before rotating. The default value is -1 (no limit). For more information on log file rotation, see Log file rotation. - The
maxsize
option specifies the maximum log file size. Log files will be rotated automatically when the specified size is reached. The default value is -1 (no limit). - The
console
option allows you to redirect logs to the standard output. - The
syslog
option allows you to redirect logs to the system log on Unix-like and macOS platforms only.Warning:The syslog feature can not be enabled on Windows®.
Log filenames
- fglWrt creates fglwrt.log
- greWrt creates grewrt.log
If logs are enabled and no directory provided, the output goes to stderr.
If you enable the debug
category, additional files will appear with the extension
.dlog. The .dlog logs are encoded and are not intended to be readable by
users. These may be requested by your Four Js support center if you encounter issues.
Log file rotation
Log rotation is the cycling through of log files: starting a new log file when necessary, re-shuffling the remaining log files to keep them orderly, and removing older log files to free up space.
Let's consider the log files for the fglWrt license controller. The current log file is always named fglwrt.log. When it comes time to rotate the log files, the license controller rotates, renames and renumbers the log files: fglwrt.log becomes fglwrt.1.log, fglwrt.1.log becomes fglwrt.2.log, and so on.
Configure automatic log rotation with the maxsize
and maxfiles
elements in the license controller configuration file (fgllicense or
grelicense). When the current log file reaches the maxsize
,
the license controller closes the file. It deletes the log file whose number exceeds the
maxfiles
value and renames the other log files in the sequence by increasing their
file number by one to make room for a new file. It then creates a new current log file
(fglwrt.log or grewrt.log).
Force a log rotation on demand with the --log-rotate
option of the
license controller (fglWrt or greWrt); for
example:
fglWrt --log-rotate
This
command forces a log rotation. It closes the current log file and starts a new log file, just as if
the log rotation had been triggered by the maxsize
value. You may wish to force a
log rotation when you are asked to send a log file to Four Js, or move a log file to another
location. This command and option can be executed at any time; even while log files are in use.