perl -pi.bak -e 's/this string/that string/g' some.file