Microsoft Vista updates and Linux bootloader

Some of the Microsoft Vista system updates (like service packs) need to have MBR of your system disk clean, that is without any foreign bootloader. Otherwise you'll get ambiguous error code like 80004005 in failed update notification dialog box.

If you have dual boot set up the easiest way to still update your Windows OS is to:

  1. temporarily save MBR
  2. clear MBR of your bootloader
  3. update Windows OS
  4. restore old MBR

To save your MBR use dd command such as: dd if=/dev/sda of=sda-grub.dd bs=512 count=1

To clear bootloader like GRUB from MBR so that Windows could update cleanly, boot from your Microsoft Vista DVD and in System Rescue Command Prompt execute: bootrec /fixmbr

Restart your computer, and I'll go straight to you Windows OS where you can update your system as usual.

Now to restore your old bootloader, boot your system with your Linux distribution DVD and execute: dd if=sda-grub.dd of=/dev/sda bs=512 count=1

As an added benefit, you might want to save clean Windows MBR in a separate file (like sda-vista.dd) before you restore your old MBR. That way, you won't need to boot into Windows rescue mode again, but use Linux and dd command only.

A couple of notes:

  • Substitute /dev/sda with your disk designation in above commands
  • Be careful with dd command when you're dealing with partitions.
  • Note that you save first 512 bytes of your disk, so that this saves partition table as well

N:: on 08/21/2010