UnixServerAdmin

Server Administration & Management

Backup partition table and bootloader

We can backup the MBR record of a hard-drive. The MBR record contains the partition table and bootloader.

Having a backup of the MBR is important and useful in case, when you want to copy data from an older drive to a new one or in case you want to restore data from a damaged drive.

How to backup the MBR record

# dd if=/dev/sdX of=MBR.bck bs=512 count=1

Note : you have to replace /dev/sdX with your actual drive. This can be /dev/sda, /dev/hda, etc.

How to restore de MBR record

# dd if=MBR.bck of=/dev/sdX bs=512 count=1

Again you have to replace /dev/sdX with your actual drive. If you also want to keep a human readable copy of the partition table you can run:

# fdisk -l > part.table

Advertisements

January 24, 2011 - Posted by | Tips & Tricks, Unix/Linux | , ,

2 Comments »

  1. Continue to write regarding this topic. Presently there is a higher demand than you may expect for this type of knowledge and guidance. That which you talk about is useful to the person who is looking to get the suggestions that you’ve assembled.

    Comment by fresh water | June 15, 2011 | Reply

  2. I’ve recently been browsing for specifically these details. While I was expecting to find this content I’m really impressed that your experience was so easy to find and just how it properly compared to my own experience.

    Comment by blog about water | June 16, 2011 | Reply


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: