linux

Find and replace text in multiple file in Linux console

 find . -name '*.txt' | xargs perl -pi -e 's/oldtext/newtext/g'

examples:
find . -name '*.txt' | xargs perl -pi -e 's/From: root/From: csf\@donie\-centos5\.slowrock\.com/g'
find . -name '*.txt' | xargs perl -pi -e 's/To: root/To: donie\@slowrock\.com/g'