copy corrupting last block of file?

G.Wolfe Woodbury redwolfe at gmail.com
Fri Dec 21 00:16:59 UTC 2012


On 12/20/2012 06:48 PM, Tom Horsley wrote:
> This looks suspiciously like a software problem of some kind:
> 
> I've got a file (a firmware update) I try to copy to an sdcard.
> 
> Two different copies now have shown as corrupted at the start
> of the final 16K boundary of the file data:
> 
> zooty> cmp /zooty/public/S800CUpdate/firmware/firmware.bin /tmp/tom/bad-linux-firmware/firmware.bin 
> /zooty/public/S800CUpdate/firmware/firmware.bin /tmp/tom/bad-linux-firmware/firmware.bin differ: char 127041537, line 496168
> 
> zooty> cmp /zooty/public/S800CUpdate/firmware/firmware.bin /tmp/tom/firmware/firmware.bin 
> /zooty/public/S800CUpdate/firmware/firmware.bin /tmp/tom/firmware/firmware.bin differ: char 127041537, line 496168
> 
> That 127041537 value in hex is 0x7928001.
> 
> Worst yet, if I use rsync rather than cp to copy the file, lo and behold the
> contents turn up identical!
> 
> Is the "cp" command busted? That would be insane.

Yes, it would be insane.
It is much more likely to be a hardware problem.  Try another large file
copy to the sdcard and see if something similar happens.

Then try a different sdcard.

-- 
G.Wolfe Woodbury
FAS: redwolfe (proventesters)




More information about the users mailing list