I just set up a FreeNAS server with a terabyte drive. I want to only have one hard drive in each machine so I have been taking as much data as possible and sending it over the LAN to FreeNAS. I have noticed at least one file didn't copy properly and is now corrupt. (I am also noticing some strange permission issues, but that is another question.) Now that most of the data is over on the FreeNAS server, is there an automated way of verifying nothing else is corrupt?
I am not exactly sure how to describe how the file was corrupt. Basically it appeared to be a 178 megabyte video file, but when accessing it to play or even move, the windows machine accessing it gave a generic could not access error message. I used FreeNAS's web copy interface to move the file, once it was moved, the file was 76 megs, and could not be played.
Always run:
and then
before and after copying a large amount of data.
You'll be surprised how much random data corruption you experience in the real world.
When you find a corrupt file,
cmp -l badfile goodfile
to attempt to understand the nature of the corruption.This is why I beg for end-to-end integrity checking in all cases. Unfortunately filesystem and OS vendors do not take this seriously.
You can check Aide. I guess there's other integrity tools out there.