Note that there are some explanatory texts on larger screens.

plurals
  1. POFinding missing files by checksum
    primarykey
    data
    text
    <p>I'm doing a large data migration between two file systems (let's call them F1 and F2) on a Linux system which will necessarily involve copying the data verbatim into a differently-structured hierarchy on F2 <strong>and</strong> changing the file names.</p> <p>I'd like to write a script to generate a list of files which are in F1 but <strong>not</strong> in F2, i.e. the ones which weren't copied by the migration script into the new hierarchy, so that I can go back and migrate them manually. Unfortunately for reasons not worth going into, the migration script can't be modified to list files that it doesn't migrate. My question differs from <a href="https://stackoverflow.com/questions/1772675/find-missing-numbers-in-continuous-filenames-advanced-ls-find">this previously answered one</a> because of the fact that I cannot rely on filenames as a comparison.</p> <p>I know the basic outline of the process would be:</p> <ol> <li>Generate a list of checksums for all files, recursing through F1</li> <li>Do the same for F2</li> <li>Compare the lists and generate a negative intersection of the checksums, ignoring the file names, to find files which <em>are</em> in F1 but not in F2.</li> </ol> <p>I'm kind of stuck getting past that stage, so I'd appreciate any pointers on which tools to use. I think I need to use the 'comm' command to compare the list of file checksums, but since <strong>md5sum</strong>, <strong>sha512sum</strong> and the like put the file name next to the checksum, I can't see a way to get it to bring me a useful comparison. Maybe <strong>awk</strong> is the way to go?</p> <p>I'm using Red Hat Enterprise Linux 5.x.</p> <p>Thanks.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload