Configure logging behavior

Your Tricentis License Usage Tracking statistics show you potential licensing bottlenecks or low consumption. So you can make sure that your testers have the licenses they need, when they need them.

By default, the service logs important events to %ProgramData%\Tricentis\LicenseUsageStatistics\LicenseUsageStatistics_Log.txt. It has a daily rolling interval and keeps a maximum of 60 log files. This means that at the end of every day, the service performs the following actions:

  • It starts a new log file.

  • It deletes the oldest surplus file.

If you want to change this logging behavior, follow these steps:

  1. Open the file LicenseUsageStatistics.exe.config. After a default installation, this file is located at C:\Program Files\TRICENTIS\Tricentis License Server\License Usage Tracking.

  2. In the appsettings section, modify the following settings:

Setting

Description

LogLevel

Specify the Serilog log level you want to use. If you run into an issue and need to contact Tricentis Support, make sure your logs are on Information level.

LogPath

Specify the full path to your log files. The service adds a date and time stamp to the file name.

RetainedFileCountLimit

Specify the maximum number of log files that the service should keep.

RollingInterval

Specify the rolling interval for your log files: Minute, Hour, Day, Month, Year, or Infinite. If you choose Infinite, the service writes all log events into a single file and never deletes any files.

  1. Save and close the file.

  2. Restart the TricentisLicenseUsageTracking service.

In this example, you configure the following logging behavior:

  • The service logs on Warning level.

  • It saves all log files to C:\MyFolder\My_logs.txt and adds a date and time stamp to the file name.

  • The service keeps a maximum of 20 log files.

  • It starts a new log file every Month. If the new log file is the 21st log file, the service deletes the oldest file, so you only have 20 files left.

<appSettings>

[...]

<!--Logging settings-->

<add key="LogLevel" value="Warning" />

<add key="LogPath" value="C:\MyFolder\My_logs.txt" />

<add key="RetainedFileCountLimit" value="20" />

<add key="RollingInterval" value="Month" />

<!---->

</appSettings>