compare two directories integrity after copy

Rashkae ubuntu at
Sat Sep 24 22:01:03 UTC 2011

On 09/24/2011 05:40 PM, Mazen A. wrote:
> On 11-09-24 01:10 PM, Liam Proven wrote:
>> On 24 September 2011 21:06, Mazen A.<lists at>  wrote:
>>> Hello,
>>> I have copied a rather large directory from one external usb disk to 
>>> another
>>> using rsync. I chose to not go with the checksum check option 
>>> because it
>>> will take a long time (256GB of data). Is there any known way I can 
>>> make
>>> sure that everything was copied correctly after the fact?
>> You could use 'md5sum' to generate checksums and compare them, I
>> think? It will take a good while, though...
> Thanks, Liam. I believe md5sum works on the file level and not 
> directories. Are you aware of the same for directories?
It's more than a little rough around the edges, but this is the script I 
use to create an md5 file for multiple directories.  Run it in the root 
directory from where you want to start the MD5SUM file

find ./ -type f -print0 | xargs -0 md5sum > /tmp/mkmd5 && \
mv /tmp/mkmd5 ./MD5SUM

More information about the ubuntu-users mailing list