Agent log files display the total log file count and size with the following default values:

  • Log file count: three
  • Log file size: 2MB, each

Log File Customization

You can change the size and number of log files using the config.properties file where you can assign count of log files and assign a specific common size to all. For example, if you have assigned a log file count of four, you can assign 25MB for size. Each log file is assigned the same size. If you want five log files consumming 100MB, assign a size of 20MB. The maximum agent log file size cannot exceed 100MB.

To customize log files:

  1. Open the configuration.properties file in the applicable agent installation directory:

    • Default Installation:
      • Windows: C:\Program Files (x86)\OpsRamp\Agent\conf\configuration.properties
      • Linux: /opt/opsramp/agent/conf/configuration.properties
    • Custom Path Installation:
      • Windows: {custom_dir}\OpsRamp\Agent\conf\configuration.properties
      • Linux: {custom_dir}/opsramp/agent/conf/configuration.properties
  2. Set the parameters to the values you want. For example:

        log_file_count = 4
        log_file_size_mb = 25
        

Enable Log Debug Mode

Prerequisites:

  • The agent is online.
  • You have access to the Remote Command function.
  • The agent has Remote Command functionality enabled, which can be done when the agent is installed.

Default severity level: Warning

  1. Navigate to Infrastructure > Resources.

  2. Select a device, and click the Remote Command icon to display the Commands screen.

    bootstrap

  3. From the Commands Name menu, select Enable Agent Log Debug Mode.

  4. From the Duration menu, select the duration option:

    • 10 minutes
    • 30 minutes
    • 60 minutes

    Debug log level is enabled for the specified duration, from the time the command is executed. When the duration expires, agent logs revert to the default severity level: Warning.

  5. Click Execute Command and accept the confirmation message.

View Agent Log Files

You can view and copy agent log files directly from the console. To view the agent log files, make sure:

  • The agent is online.
  • Access is available to the Remote Command function.
  • The Remote Command functionality is enabled for the agent, which can be done when the agent is installed.
  1. Go to Infrastructure > Resources.

  2. Select a device, and click the Remote Command icon.

  3. From the Command Name menu, select Show Recent Agent Log.

  4. From the Number of Lines menu, select the number:

    Available line options:

    • 100
    • 200
    • 500

    Based on the number selected, the log files are displayed on the same screen. Then, you can use the clipboard to copy the displayed lines of log files. For example, if you select 200 lines, 200 lines of log files display on the same command screen. Log files may exceed 200 lines. But, this option displays the latest 200 lines only.

  5. Click Execute Command.

The commands screen displays the requested number of lines and provides a copy option.