0

I know how to delete/rename files on reboot http://blog.notfaqs.com/2007/10/registry-rename-file-on-reboot.html. But would like to find out how to delete registry keys on reboot as well.

I want to delete the Symantec Endpoint Protection key but I cannot. I tried to give myself permission but "Access Denied". I even tried using the NT AUTHORITY/SYSTEM account which is supposedly the highest privilege account but unfortunately it still doesn't work.

How do I delete registry keys on the next reboot?

0

Why not simply uninstall SEP normally?

To answer the question though... I am not in front of a Windows machine to verify right now, but IIRC the main SEP service is not listed in services.msc, i.e. the Services Control Panel applet. Try a RunOnce entry with something like this, proceeding at your own risk because deleting the wrong key in the Registry can irreparably damage your OS:

cmd.exe /c "c:\path\to\Symantec Endpoint Protection\bin\smc.exe" -stop && ping -n 60 127.0.0.1 && reg delete "HKLM\Software\path\to\the\key" /f

Info on RunOnce, et al., can be found here. The ping... gives you a 60 second pause for the service to shut down. Smc.exe returns immediately as I recall.

All that said, if the only thing preventing the deletion of the key is that the SEP service is running, you can try running the smc -stop command first as an admin, then deleting the key from within regedit.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.