You can remove the Collector role instances using the Remove-RoleInstance utility supplied with the Collector role. The utility removes the packages of the role and its modules and files from the role data storage directory.
/opt/deployer/bin/Remove-RoleInstance.ps1
When starting the utility, you can also use the special key host <name of the host on which the role instance is located>
. For example, /opt/deployer/bin/Remove-RoleInstance.ps1 -host user-minion*
. In this case, the role instance is removed without confirmation. You can specify only one host name for each key.
You can check whether or not the role packages and its modules were removed correctly using the dpkg -l | grep agent
command. The removed role instance will no longer be on the collector list on the System → System management page, on the Collectors tab. The /var/log/core-agent
and /opt/core-agent
directories will also be removed.
If during the first run of the utility you failed to remove all data, you can restart the utility until all data is removed.