Gentoo Archives: gentoo-user

From: Eric Bohn <bsee_1991@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Re: dual boot: XP installed last?
Date: Wed, 01 Nov 2006 21:30:23
1 You can also backup and and restore the MBR using the Linux dd program available on the Gentoo LiveCD.
3 >From :
5 dd if=/dev/hda of=backup-of-hda-mbr count=1 bs=512
6 This stores the first 512 bytes of the disk (contianing the MBR and the primary partition info - i.e. the first four primary entries) into the file "bcakup-of-hda-mbr" which you can then copy to somewhere safe.
7 To restore (be careful - this could destroy your existing partition table and with it access to all data on the disk):
8 dd if=backup-of-hda-mbr of=/dev/hda
9 If you only want to restore the actual MBR code and not the primary partition table entires, just restore the first 446 bytes: dd of=/dev/hda if=backup-of-hda-mbr bs=446 count=1. (Those first 512 bytes are 446 bytes of MBR, then 64 bytes of primary partition table).
13 --
14 gentoo-user@g.o mailing list