How to replace Windows replication agent's config file in case a machine is shown offline in ACP

How to replace Windows replication agent's config file in case a machine is shown offline in ACP

Challenge

A machine is shown offline in ACP, although the source instance is running and has been replicated successfully before.

Cause

The replication agent's config file might have become corrupted during an unexpected termination of the repman process.

Solution

Replacing a faulty config file is necessary. 

1) Check the current config at [ProgramData]\Hystax\acura\repman.conf for any visible discrepancies. It might be an empty file if corrupted.

2) Download a new installation package for the Windows replication agent. 
This will be a .zip archive containing a .msi installer and the repman.conf file next to it.

3) Stop the hwragent service on the machine and make sure that there are no repman processes running. Terminate the existing ones if present.

4) Replace the old configuration file with the new repman.conf from the archive.

5) Start the hwragent service once again and after a few minutes check whether the machine has become online in ACP.
The machine should have a green circle next to its name to indicate that it is properly discovered.