Everyone has experienced this since Windows 98 was out, and it seems to be getting worse as each new version comes to market: it takes so long to shut down the computer that it seems like there’s time to have a cup of coffee while reading War & Peace.
At times, the computer has updates it has to install before shutting down. But other times, when there seems like there’s nothing to do, it could take almost a full minute before the screens go black and you can say “nighty night” to your computer. What’s happening? Why is it taking longer to shut down your computer than it takes you to visit the washroom?
Windows Is Trying to Protect You
Like that excessively cautious buddy you have, Windows is doing everything it can to ensure that everything is in order before it goes into that deep sleep. The end of the shutdown process results in the termination of all of the system’s operations.
Unlike going into sleep mode, where the computer just freezes everything in place and even keeps the RAM running, shutting down means emptying everything. RAM goes completely blank, nothing is cached, the hard drive empties all the contents of its virtual memory of all programs, each and every application you had running shuts off, and the operating system says “goodbye” to its services.
There’s a lot of software running on your computer. If it all just shut off while it was in the middle of something without getting the time it needs to finish doing it (e.g. a program is busy writing to the disk), it might sometimes lead to chaotic circumstances that yield an error when you start up your computer again.
Although it’s quite rare for a “hard” shutdown like what I just described to harm your computer, Windows is ever-cautious about your data. To prevent file corruption, it waits until every program finishes what it’s doing before completing the shutdown process. This could, in theory, take anywhere from a second or two to several minutes.
The Windows shutdown process is not as straightforward as it seems. There’s no magic behind it; it’s a series of steps the operating system follows to turn your system off safely:
- Check whether there are any open applications with unsaved data (Notepad, Word, etc., with input that hasn’t been saved). Interrupt the shutdown process and inform the user if anything is found.
- Wait for all services to stop what they’re doing, then shut them all down.
- Wait for all programs and services to tell you that they have closed.
- Empty virtual memory and anything else that was holding temporary program data that is now useless.
- Write a log with anything interesting that the user might use to report problems in case Windows starts with new errors that might be related to shutdown.
- Log everyone out of the system.
- End the Windows user-level operating system.
- Install any updates, including and especially those that are kernel-level and require special permission.
- Turn the machine off (finally!).
All of this, by design, ensures that Windows will not throw you any errors when you next start it up. But because there are so many safeguards in modern applications, most of these protections aren’t as necessary as they were in the late 90s. Linux, for example, often takes much less time to shut down.
If you want to speed up the shutdown process in Windows, the easiest way to do it is using our own guide!
What was the longest you’ve ever waited for Windows to shut down? Tell us in a comment!