Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Modifications' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Modifications
Authored by: MarcusB on Aug 30, '01 03:28:13AM

Great Tip.
To get it working in ksh, I had to change the syntax as below ( I suspect the change is generic). After these changes its fine.

The correct sysntax in ksh is

find . size +20 ! -type d -exec cksum {} ";" | sort | tee /tmp/f.tmp | cut -f 1,2 -d ' ' | uniq -d | grep -hif - /tmp/f.tmp > dup.txt

The only changes are to the find command.



[ Reply to This | # ]
Modifications
Authored by: qka on Aug 17, '04 04:36:56PM

This example works in bash, as supplied with Panther (10.3).

Note that a sufficiently large set of files, grep, and hence the whole command, will fail.

I was trying to find duplicates in a set of approximately 26,000 files, with about 50% duplication when I discovered this.



[ Reply to This | # ]