You can run the following command lines with a pause between each one to give each commnad time to complete before proceeding to the next...
- aexruncontrol.exe /deletedevices
- aexruncontrol.exe /uninstallagents
- aexruncontrol.exe /clean
This will ensure removal of almost all legacy and current plug-ins, device drivers etc. before attempting to install a new agent.
An addtional piece you can add as well is to include the uninstall strings for each subagent in case they exist and run those first using standard .MSI command lines. If they don't exist the command will just error out and continue on. But if they do then it will execute the uninstall first. I use this first in my deployment scripts to esnure I rmeoving agents/installs using the cleanest/built-in process first before trying the brute method of the aexruncontrol switches.