When I write a large file ( > 350 MB ) to a microSD card, I almost always get one or more corrupted 4KB blocks of data in the file. The file size is correct but an md5sum of the new file does not match the original. Using 'cmp' I see where the data looks shifted by one byte for about 4 KB then the data is correct again. The audio and video files I initially wrote did not seem corrupted. I didn't see the error until I copied a tarball image and something 'important' got corrupted.
My setup is a Verdex XM4, console-vx, and netmicrosd. I first noticed the problem with pre-built 308M versions of u-boot, uimage (2.6.21), and rootfs (basic). I have since loaded the pre-built images of 318M versions of each, trying both glibc and uclibc combinations of the kernel and fs. (The pre-built kernel images are still 2.6.21). I still have the problem.
My current test file is a tar image of the gumstix-oe directory (tar cf gs-oe.tar gumstix-oe/). The file is about 390 MB.
I can use scp to write the file to the microSD card:
scp gs-oe.tar firstname.lastname@example.org:/media/card/test.tar
I've ruled out the ethernet interface by buying a microSD USB card reader/adapter and copying the file directly to the microSD card then with the microSD card in my gumstix:
dd if=/media/card/gs-oe.tar of=/media/card/test-2.tar
I've done this test several times (with various 'dd' block sizes) and rarely did the file get written without an error.
I've tried several microSD cards:
SanDisk 1GB (2)
SanDisk 8GB (SDHC)
I have tried a different netmicrosd board with the same results. I have a 'new' netwifimicrosd board on order.
Any suggestions on how to resolve this would be greatly appreciated.