Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a (semi)-dead hard drive with an HP recovery partition on it.

My goal is to

  1. Buy a new hard drive
  2. Copy the recovery partition to a drive ( dd if=/dev/sdb1 of=~/recovery.bak )
  3. Make a new partition of 12000 mb with Windows 7
  4. Copy back recovery partition to the new drive ( dd if=~/recovery.bak of=/dev/sdb1 )

Then press F11 when the laptop boots. However, this doesn't work. Any idea why?

Edit:
I suspect the F11 doesn't work because the laptop tries to boot the laptop, because my partition is the primary partition of the drive.

Does anyone have any experience dealing with stuff like this?

share|improve this question
    
Can you try by plugging a USB keyboard in your laptop? Then, press F11. Parles-tu francais aussi? –  r0ca Mar 24 '10 at 12:16
add comment

1 Answer

I've successfully done things like what you describe. When I do this, I boot up off of a Linux USB drive (Slax Linux is easy for this) so that I don't have the disk drives being used by the OS while I do my work. Then I would use fdisk or parted or gparted to partition the new disk. Best and easiest is to have the same partitioning on both disk drives. Once partitioning is done, you can dd from a partition on one drive to a partition on the other drive (e.g. dd if=/dev/sda1 of=/dev/sdb1). You can use fdisk to set the partition to "active". In many cases, it's easier to copy the entire drive first (e.g. dd if=/dev/sda of=/dev/sdb) and then use gparted or other tool to resize or move partitions (if needed). In your case you could try the complete disk copy, and if/when it fails, follow up by copying just the partition(s) you are really interested in.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.