Blib...Blog...Blib...

Thursday, December 15, 2005

A good reason to disable?

[Update: Guy Kewney from Newswireless.net has just commented on the same in an article on TheRegister]

OK, so the subject of this article/rant is Microsoft's Automatic Update mechanism in Windows XP. A lot of people might correct me there and say, "Well, it's actually Windows XP SP2", but they would be wrong as it was there way before then....

Anyway, just before I left work last night, I set some unit tests running to check over some last minute changes that I'd made to code. It was pointless waiting around for the results, because a) I had a dinner date 60 miles away and had to beat the rush to get there, and b) Even if the tests failed, I wouldn't be making any changes until today. So, I came in this morning to find that an update had been performed that required a reboot, and that Windows had dutifully obliged itself and rebooted.

The test results, are not an issue, because I'll be able to view the report anyway; but there are a few questions that come out of this:

  1. What sort of mechanism is used for saving unsaved work before rebooting? Is all work pending saving actually saved, or (more likely) does the Application Not Responding box pop up, wait for you to click the End Now button for 30 seconds and then just kill the app anyway.
  2. It seems unlikely that MS would be silly enough to take it upon themselves to decide which work requires saving and which doesn't, as lots of very important work could be lost because of this. Say, for example, that I have was doing my final year project for a degree, and it was all done but I needed to relocate a few sections, so I have highlighted a huge section of work and cut it to the clipboard. Then the phone rings, and it's my mate telling me to get myself round there because it's time I had a drink to get rid of some of the stress of doing my project..... When I stumble back in 6 hours later, an automatic update requiring a reboot has occurred and my document - my lovely crafted 15000 word document - is now 5000 words lighter because I left my machine unattended for too long (I trusted it to behave like an adult and it did not)....
So, OK, number 2 obviously doesn't happen because that would get MS into a whole boat load of trouble. But I still think that there should be a button on the balloon telling you about the update, to allow you to stop this from ever happening again, and to just ask you to reboot when it is convenient for you.

Microsoft unfortunately appear to have taken the short-sighted view that, because the computer has received no input from the keyboard/mouse for 6 hours, it is not in use. According to Dictionary.com / WordNet, the definition of a computer is:
  • n 1: a machine for performing calculations automatically
and automatic:

  • adj. Acting or operating in a manner essentially independent of external influence or control

Therefore, I don't believe that it is reasonable or even safe assumption to make.

For the next version of windows, Vista, I think there there should be some sort of mechanism for the operating system to hook into programs to perform operations like save, and that all open files that require to be saved, should be saved into a special folder and not over the existing file.

The other mistake that I think Microsoft have made is that they have highly promoted the 'Security Center' as the single interface for controlling things like the Windows firewall and automatic updates. What will happen when a user wakes up one morning and the demo of Call of Duty 2 that they were downloading overnight had managed to get to 99% before auto update rebooted the machine?

Well, the chances are that the user will go straight into the Security Center to look for an option of turning the auto reboot off.... They won't be able to find it, and the closest they will get is to choose the option that downloads the updates and requires the user to confirm the installation. In my opinion, this option is not very good, because people will most likely be busy at the point that they are asked and dismiss the dialog.

Other users may interpret the fatal 'Turn off Automatic Updates' as the option that they require, thus defeating the whole purpose of the mechanism. A simple option - 'Automatically install updates, but ask for confirmation before rebooting' - would, I think, be well suited to being the 2nd option in the list.

For now, however, it is possible to turn off the automatic reboot and be able to choose when you want to reboot your machine, as follows:

  1. Go to Start->Run and type gpedit.msc, this will open the Group Policy Editor
  2. Navigate to Local Computer Policy->Administrative Templates->Windows Components
  3. Click 'Windows Update'
  4. In the right-hand pane, double-click on 'No auto-restart for scheduled Automatic Updates installations'
  5. Select the 'Enabled' radio button
  6. Click OK
  7. Sleep easy in the knowledge that your PC will still be doing what you left it doing when you wake up in the morning (barring power cuts, crashes etc...)
Another thing that you may find annoying when you are actually at your PC is the associated message box that says that a recent update requires a restart of your machine, and you can restart now or restart later; if you choose later, the same box will pop up 10 minutes later with the same options.

Follow steps 1-3 as above, then:

  1. Double-click 'Re-prompt for restart with scheduled installations'
  2. Here you can choose disabled (not recommended), or choose enabled and set the wait period below to be something more acceptable, like 60 minutes.
  3. Click OK
After this you can close the Group Policy Editor, I'm not sure whether you need to reboot after making these changes, but at least that's a decision that you can make.....

[Update: Roy Osherove has posted about a free tool called WhyReboot?, which lists pending updates for files to help you decide better whether you need to reboot. Thanks Roy.]