LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Need help copying an image to/from CF cards (https://www.linuxquestions.org/questions/linux-software-2/need-help-copying-an-image-to-from-cf-cards-162703/)

Astryk 03-26-2004 01:39 PM

Need help copying an image to/from CF cards
 
I need to setup a method to copy an image of a Linux install composed of 3 partitions from/to a USB CompactFlash card reader. Ideally, this would be possible from within Windows (or cygwin), but it would also be alright if it could be done from a bootable disk (E.G. G4U). I know this isn't a Windows forum by any means, but the utilities I'm using are *NIX-based (dd and G4U). Plus, I'm a Linux guy and I trust this crowd a lot more. :)

Using dd for Windows, I can successfully rip the image using: dd if=\\?\Device\Harddisk2\Partition0 of=c:\cf.img. However, when I try to reverse this and write back to the device using: dd if=c:\cf.img of=\\?\Device\Harddisk2\Partition0, I get the error "Error writing to file: 6 The handle is invalid. 1+0 records in, 0+0 records out.

The error is persistent whether or not the destination CF card is partitioned. I have also tried writing to the volume, which actually writes but doesn't actually work. (Can't boot, no valid partitions are created). I
also tried writing to Partition1 instead of zero, even though I am fairly certain it's Partition0 I should be writing too, but that gives the same error writing to file as Partition0.

I've also looked into using G4U. I would like to be able to rip an image and write it to something like /mnt/win/cf.img then write it back to the CF card. I can do a direct CF-to-CF copy just fine if I have two CF card readers, but I won't for long and need to be able to do this with just one. I don't think what I'm asking is possible with G4U since it's really only intended for FTP-based imaging, but it's worth an ask.

Anyhow, any help using either dd or G4U would be greatly appreciated. I'm also open to any suggestions for other open source projects that may work. Thanks!

ugge 04-06-2004 10:56 AM

Have you tried it with any other linux floppy/cd?
I would make a try with something like LNX-BBC, http://www.lnx-bbc.org/


All times are GMT -5. The time now is 12:55 AM.