Using PERL, we can easily do a search and replace across multiple files. perl -pi -w -e ‘s/SEARCH_FOR/REPLACE_WITH/g;’ FILE_LIST The following example will replace all occurrences of “hello” with “goodbye” inside files ending with .txt:
1
perl-pi-w-e's/hello/goodbye/g;'*.txt
To handle special characters, use the hex value. For example, to convert MS web files that use control characters: […]
Permission denied: could not bind to address To disable on the fly: # getenforce Enforcing # setenforce 0 # getenforce Permissive # sestatus To survive a reboot: # vi /etc/sysconfig/selinux Change: SELINUX=enforcing to SELINUX=disabled ~or~ SELINUX=permissive