Creating a Compact Flash image

Aug 30, 2007 1 Replies

Hi. I use a CF card to mount linus File System for an embedded system. I used the following production procedure for new CF-s:



  1. Create an image: - fdisk - mount the CF and untar the parts comprising the FS there - sync+unmount - create an image using dd:


  1. Once I have an image - I just used dd for every new one: dd of=/dev/sdc if=cfImage.bin bs=512 count=800



The problem: This worked fine for SandDisk 512 CF-s. It doesn't work for a bunch of new Kingston 1GB CF-s I got. The first part works fine, but I can't use an image created from one CF for another CF. If I use it for the same CF (ufter deleting it with dd from /dev/zero) - it works fine. But for some reason the image I get works only for the same CF from which it originated.



The questions: - Any idea why this can happen - Any idea for a better production procedure (its ext2fs over Linux partition in case it matters).



Thanks, Michael



Google for CHS.

Different cards are using different CHS. Unfortunately a BIOS can reprogram this mapping at runtime. Try to use these cards with LBA only, on *all* systems. Or fake a partition table with LBA entries only.

Juergen

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required