我刚刚安装了fcgiwrap和spawn-fcgi以便能够在nginx中使用perl脚本。我说这样的事情在我的网站的配置:如何获得nginx错误日志中的perl脚本错误(Nginx与FCGIwrap)
location ~ \.pl$ {
gzip off;
fastcgi_pass unix:/var/run/fcgiwrap.socket;
include fastcgi_params;
fastcgi_index index.pl;
}
它的工作原理,但浏览器会显示以下信息,如果有在Perl代码中的错误:
An error occurred while reading CGI reply (no response received)
而且我无法找到perl的错误在nginx日志中。命令行上的“perl -c”有助于解决perl编译错误,但它不能帮助我解决运行时错误。
如何告诉perl或fcgiwrap将错误保存在nginx错误日志或其他一些日志文件中?