1

I want to backup my Windows machine before I put Ubuntu on the hard drive instead.

Following the instructions on the VirtualBox website it says to create an image.dd file using dd.

I booted up from the Ubuntu live CD, connected the external hard drive and then tried to use dd to create the image with the following command:

dd if=/dev/sda of=/dev/sdb1/image.dd

However I get the following message:

 a dev/sdb1/image.dd: not a directory error

Any ideas what I'm doing wrong?

1 Answer 1

3

/dev/sdb1 isn't a directory, so you can't create a file in there.

You need to have a filesystem on /dev/sdb1 (I assume the drive exists and is already partitioned?) that can be mounted.

Then you need to mount that filesystem:

# mount /dev/sdb1 /mnt

should work.

Then you need to use

# dd if=/dev/sda of=/mnt/image.dd

Once it's finished, unmount the disk:

# umount /mnt

and you should be good to go.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .