Scripting Question

Scripting a Trend Micro Officescan removal

10/11/2017 2215 views
So the uninstaller for Trend Micro frequently fails/corrupts (not to mention you can't silently automate it through a system like Kace as it requires password entry to remove). So I'm trying to script the manual removal process, killing services and ripping out registry keys and then ultimately the appropriate program files directory itself.

The smartest way I can perceive doing this is by doing two scripts (the first is already completed). One to disable the services (as it doesn't allow you to actually stop the services outright) and the second to very the services are no longer running prior to ripping everything out (basically, a separation of scripts to ensure a reboot in the middle, so the disabled scripts don't start back up).

I need to verify that 4 processes are not running prior to the continuation of my second script. In my experiences, I've had problems verifying that multiple things are true in a single verification stage of one step. What is the appropriate way to verify that all 4 processes (services) are not running and THEN moving on to start deleting registry keys?

Thanks in advance!
1 Comment   [ + ] Show comment


  • Good Luck with that because we tried to do it but because Trend had to have a password even doing it manually it would not work. Trend gave us the script that should work and it didn't because Trend is a pain to uninstall. Hope you get it to work because we did a lot of sneakernet to make it happen here.
    • Oh I've manually done it countless times, just looking to save countless hours doing it manually for like 50 computers plus the old ones in the back we haven't booted up in a while and checked in. I'll update this with my documentation on it tomorrow when I'm back in the office. It's pretty rock solid. Tip - killing the services is significantly easier when you disable the services via the registry, start=4.
    • See "Manually Uninstalling the Client" here: https://success.trendmicro.com/solution/1039283-uninstalling-clients-or-agents-in-officescan-osce#collapseThree

      Has worked for me many many times. Having the services dead is key - you will hit brick walls in the process if anything's still running. Ultimately you want to accomplish all of those tasks, but aside from having the services stopped, it doesn't really matter in what order. You just want to break it enough that it has no chance to "defend itself" (just a mindset). Registry isn't as defended as GUI changes. You can disable stuff via registry that you cant via the services gui, prime example.

Be the first to answer this question

This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ