A machine agent is considered to be abandoned when it is not attached to any APM agents.
There are two ways to delete the abandoned machine agent:
Two of them are described below:
From controller UI:
1) Please make sure that machine agent is no longer running or reporting.
2) create a dummy application from appdynamics controller UI.
3) Associate the machine agents that you want to delete to that application.
4) delete the dummy app that you have created from step 1.
The manual step from DB:
Please follow the below steps to manually delete them from the database.
This process will ensure that they do not appear in UI. But the entries still present in the db.
SELECT * FROM machine_instance WHERE NAME = '<host-name>';
`<host-name>` is the value you got from controller UI in step 3.
UPDATE machine_instance SET historical = 1 WHERE NAME = '<host-name>';
<host-name> is the value you got from controller UI in step 3.
The controller process will take some time to remove it after marking it as historical.