To become a user that has /bin/false as shell:
# su - user -s /bin/<some shell>
$ sort FILE | uniq -D
(Must sort since uniq will only look at consecutive lines)
Can also limit the number of characters to compare, e.g. 20 characters:
$ sort FILE | uniq -D -w 20
source: http://www.linuxquestions.org/questions/linux-software-2/finding-duplicate-lines-in-a-file-617441/
The method above can be used with a list of hashes to locate identical files:
$ md5sum * > MD5SUMS $ sort MD5SUMS | uniq -D -w 32