I installed Windows 7 on an old laptop yesterday evening, so that I could experiment with Win32 API programming. I started it updating about 5 hours ago. It downloaded the updates in 30 minutes or so, but as of right now it is still installing them, and only 58% complete.
Why is this taking so long, and what can I do to hasten it?
The laptop is an HP Pavilion dv6701us, with 2 GB of RAM, a 120 GB SATA hard disk, and a dual core Pentium D CPU, for what it's worth.
Update (July 18 2015):
I've now observed this behavior on every Windows 7 machine in my household, 32 and 64 bit alike. It seems almost invariant with respect to RAM, CPU speed and number of cores, even SSD vs. HDD. All Windows 7 systems I've seen updating, take over 8 hours to install ~200 updates.
Is there anyone for whom Windows Update is not spectacularly slow?
Update (July 19 2015): here is the link to the compressed xprof file:
https://drive.google.com/file/d/0B7EgLkt64WtaWWc5YTJicThLNFk/view?usp=sharing
Update (September 14 2015):
I wasn't entirely satisfied with the answer below – can Microsoft really be shipping something that broken? – so I decided to have a go at it with Sysinternals procmon. This is what I see, over and over again, while Windows Update hangs and doesn't even start downloading stuff:
High Resolution Date & Time: 9/14/2015 8:24:12.9744097 PM
Event Class: Registry
Operation: RegOpenKey
Result: NAME NOT FOUND
Path: HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\WindowsUpdate
TID: 3376
Duration: 0.0000183
Desired Access: Query Value
That WindowsUpdate key does not exist. Could be it's supposed to be nonexistent; but I strongly suspect otherwise, seeing as it is accessed over and over and over again by the updater's service host process, in a seemingly endless loop. The question in that case, though, would be: what entries/values should it contain?
Google/Bing so far hasn't turned up anything, but I'm going to keep looking on this.
Update 2 (September 14 2015):
I tried the hotfix from here:
https://support.microsoft.com/en-us/kb/2700567
It claimed to fix some things, including something about the update service registration being missing or corrupt(!). Bizarre. This is a fresh Windows 7 SP1 install.
… However, Windows Update is still just as slooooooooow as before, chugging away at 50% of available CPU power while appearing for all the world to be stuck in an endless loop.
I just don't understand this. Windows has 90% of the desktop user base, it cannot possibly be this awful by default… I will keep investigating.
Best Answer
Starting with Windows Vista the Updates come as difference files. So during setup, Windows need to creates the real files based on the diffs. This is CPU intensive and takes some time especially on really old CPUs like your Pentium D.
In your provided xperf file you have a high CPU usage from TrustedInstaller because it needs to create a
pending.xml
. This means that the updated files were in use and had to be updated during shutdown/boot which results in this dialog:Here the CPU is busy writing the XML data
and writing data into the registry
wcp.dll!Windows::Rtl::SystemImplementation::CKey_IRtlKeyTearoff::CreateNewKey
.But the bigger issue is that you try to install 5 .Net Framework updates:
Now Windows is busy because the .Net optimizer service
mscorsvw.exe
runs to compile the updated .net files into machine code to improve performance and reduce memory usage of .net applications.This is also very CPU extensive and your
Intel Atom CPU N270 @ 1.60GHz
is too slow.Microsoft provided a script to speed this up.