Debug mode - Windows executable

By default the agent will log warnings and errors but if you are having problems with the agent not reporting certain metrics or with your plugins, you can enable debug mode which will log every action the agent takes.

1. Browse to the agent directory

Browse to the Server Density directory. This is usually C:\Program Files (x86)\Boxed Ice\Server Density.

2. Create a debug config

Copy BoxedIce.ServerDensity.Agent.WindowsService.exe.config to a file called BoxedIce.ServerDensity.Agent.exe.config and open this new file in a text editor such as Notepad.

3. Set up a debug logger

Within the <configsections> node, ensure that the following exists, if it doesn't add it:

<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"></section>

Check if the log4net section already exists, and replace it with the following. If it doesn't exist add the following into the <configuration> node:

    <appender name="ConsoleAppender" type="log4net.Appender.ConsoleAppender" >
      <layout type="log4net.Layout.PatternLayout">
        <conversionPattern value="%date [%thread] %-5level %logger [%ndc] - 
%message%newline" />
    <appender name="FileAppender" type="log4net.Appender.FileAppender">
        <file value="log-file.txt" />
        <appendToFile value="true" />
        <layout type="log4net.Layout.PatternLayout">
            <conversionPattern value="%date [%thread] %-5level %logger 
[%property{NDC}] - %message%newline" />
      <level value="ALL" />
      <appender-ref ref="ConsoleAppender" />
      <appender-ref ref="FileAppender" />

4. Save the changes

Save the changes then double-click BoxedIce.ServerDensity.Agent.exe. The log file will be created in this directory as log-file.txt Debug output will also be visible in the console.

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request


Monday  —  Friday.

10am  —  6pm UK.

Dedicated Support.