Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

At which time in the shutdown sequence does a shutdown script added in the Group Policy Editor in W2k3 run?

I have a couple of 3rd Party applications which run at startup but which always produce General Exceptions during shutdown. I have made a .BAT file with a couple of TASKKILL /F /IM lines which does successfully shut down these apps without an exception when I run it directly.

But I still get the exceptions when shutting down the machine. Later in the shutdown sequence the on-screen message says "running shutdown scripts". Ideally I'd like my .BAT to run first before the rest of the shutdown process. Otherwise someone always needs to be physically at the server to dismiss the Application Error dialogs.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

How are you shutting down the machine? You could write a "shutdown.bat" script that calls your taskkill functions and then executes a shutdown command to actually shut down the machine. Then use that script instead of the shutdown button when shutting down the machine.

share|improve this answer
    
OK, thanks. That worked. I just need to educate the other administrators that they have to shutdown this server using that method instead of the usual one. Not the best solution, but workable. –  rwired Jul 17 '09 at 9:02
    
It would still be nice to get more 'inside' the windows shutdown process though (like you can *nix). So I can get a proper solution to this problem that doesn't require educating staff. –  rwired Jul 20 '09 at 5:54

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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