页面如下显示
"Server error! The server encountered an internal error and was unable to complete your request. Error message: Premature end of script headers: test2.pl If you think this is a server error, please contact the webmaster Error 500"
log里面是这样
Premature end of script headers error
参考http://sakaguch.com/PastBBS/0015/B0008334.html#No8365
#!/usr/local/bin/cgi ↓ #!/usr/local/bin/cgi -- 或 #!/usr/local/bin/cgi -
附查找替换方法 注意单引号的区别
sed -i 's/!//usr//bin//perl/!//usr//bin//perl --/g' `find . -type f`
sed -i 's/!//usr//bin//perl/!//usr//bin//perl --/g' `find -R . -type f` -R递归
同时替换多个
sed -i 's/aa/AA/;s/bb/BB/;s/cc/CC/g' `find . -type f`
sed -e's/aa/AA/g' -e's/aa/AA/g' -e's/aa/AA/g' filename