Using dd to backup a partition.
I am not sure if this question was asked before, searched for this question in different possible combinations in google and couldn't find an answer. I am hoping find an answer in this forum.
The problem I have,
I had a partition of size 3068252x1k (/dev/hda1 - reiserfs), used the following command to back up this partition,
dd if=/dev/hda1 of=linux_reiser.file bs=1k count=3068252
burned this linux_reiser.file into a dvd using dvdrecord,
dvdrecord -dev=0,0,0 -driveropts=burnfree -eject linux_resier.file
Now, I had to delete all the partitions and on my first Trial to restore, here is what I did,
reboot the system with a slackware cd and tried this command,
using fdisk create a partition of size 2996 MB = 3068252x1KB.
dd if=/dev/hdb of=/dev/hda1 bs=1k count=3068252
I get a message that no space is left in /dev/hda1. I increased the partition size by 1 cylinder each time and tried it until the dd command could successfully write all the bytes. However I see that the partition is not restored, as I cannot boot from this disk. This partition is marked as bootable.
Thanks in advance.
|