First I have wrote perl script to do that. It was a quick way :-). But today I have found more elegant solution:
#grep -v -f friends.txt access_log>new-file
- -v, --invert-match
- Invert the sense of matching, to select non-matching lines.
- -f FILE, --file=FILE
- Obtain patterns from FILE, one per line. The empty file contains zero patterns, and therefore matches nothing.