Q
Manage Learn to apply best practices and optimize your operations.

How to run a batch file at system shutdown

Learn two ways admins can run a batch file at system shutdown in this desktop management Ask the Expert Q&A.

How do I run a batch file at system shutdown?
There are a couple of ways to do this. You can edit Group Policy, under Computer Configuration | Windows Settings | Scripts (Startup/Shutdown); there you can add entries for any number of things to run at shutdown. Or, you could create a batch file which runs whatever you want and then shuts the computer down by using the SHUTDOWN command. Depending on your needs, you can use either approach.

Dig Deeper on Windows Server troubleshooting

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchServerVirtualization

SearchCloudComputing

SearchSQLServer

SearchEnterpriseDesktop

SearchVirtualDesktop

Close