Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Changing configuration with Templates in a Stand-alone Deployment

Supported Version: WinCollect 7.2.8 + stand-alone only. With templating, you can change the Agent configuration without making manual or scripted edits to the AgentConfig.xml file.

When you copy a template to the WinCollect patch directory, the Agent replaces the existing configuration with the contents of the template. Before the Agent applies the changes from the template, it makes a backup of the current configuration in the patchcheckpoint directory. After the changes are applied, the Agent restarts and uses the new configuration.

Four sample templates are installed with WinCollect 7.2.8 and later. They are stored in the \JSA\WinCollect\templates directory.

  • tmplt_AgentCore.xml

  • tmplt_DestinationManager.xml

  • tmplt_DeviceWindowsLog.xml

  • tmplt_PayloadRouter.xml

Note:

These templates are examples only. All Agent configuration service modules are supported, so that you can create your own templates.

The following use cases are examples of how you can use templates to change Agent configurations.

Use Case 1: Change Heartbeat Interval

You want to change the heartbeat interval from 5 minutes to 1 hour on all deployed systems. Previously, this required manual or scripted changes to the agentconfig.xml file and a WinCollect service restart. With templates, you can change this interval by performing the following steps.

  1. Locate the tmplt_AgentCore.xml template in the \IBM\WinCollect\templates directory. This service contains the Heartbeat Interval configuration.

  2. Make a copy of the template and name it service_AgentCore.xml.

  3. Change the value of the HeartbeatInterval parameter to 3,600,000 milliseconds (1 hour).

  4. Move the service_AgentCore.xml file to the \IBM\WinCollect\patch directory. After a few seconds, the file disappears and the agent restarts. The old agentconfig.xml file is moved to the backup directory (patch_checkpoint_xxxx).

Use Case 2: Modify Event Data Storage Configuration

You want to change the location and capacity of the event data that is stored in the \programdata\WinCollect file. You want to store the event data in C:\WinCollect\Data and change the capacity to 20 GB. There is no default template for this change, but you can easily create one by using information in the agentconfig.xml file. The following sample shows the existing service:

Note:

%ALLUSERSPROFILE% is an environment variable. The default value is C:\ProgramData. You want to change this value to C:\WinCollect\Data.

  1. Create an XML file named service_DiskManager.xml with the following contents:

  2. Move the file to the \IBM\WinCollect\patch directory.

    After a few seconds, the file disappears and the agent restarts. Data is now written to the new directory.

Use Case 3: Send TCP instead of UDP

You want to send Syslog data to JSA over TCP rather than UDP. You must specify this option in the Destination Manager.

  1. Locate the tmplt_DestinationManager.xml template in the \IBM\WinCollect\templates directory.

  2. Make a copy of the template and name it service_DestinationManager.xml.

  3. In <Module order=”4"> service_name=""UDPSendStage">, change the service_name parameter to TCPSendStage.

  4. Move the file to the \IBM\WinCollect\patch directory. After a few seconds, the file disappears and the agent restarts. The old agentconfig.xml file is moved to the backup directory (patch_checkpoint_xxxx).

Use Case 4: Add NSA Filtering to an Existing Log Source

You want to add NSA filtering to an existing log source. You can change this attribute by using the tmplt_DeviceWindowsLog.xml template.

  1. Locate the tmplt_DeviceWindowsLog.xml template

  2. Make a copy of the template and name it service_DeviceWindowsLog.xml.

  3. Open AgentConfig.xml and locate the log source contained in the module DeviceWindowsLog.

  4. Copy the model and instance information and replace the contents in service_DeviceWindowsLog.xml with it.

  5. Modify the following lines with the bolded sample code:

  6. Save the service_DeviceWindowsLog.xml file and move it to the file to the \IBM\WinCollect\patch directory. After a few seconds, the file disappears and the agent restarts. The old agentconfig.xml file is moved to the backup directory (patch_checkpoint_xxxx).