每个虚拟主机的 error_log? [英] error_log per Virtual Host?
本文介绍了每个虚拟主机的 error_log?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在一台运行 Apache 和 PHP 5 的 Linux 服务器上,我们有多个带有单独日志文件的虚拟主机.我们似乎无法在虚拟主机之间分离 php error_log
.
On one Linux Server running Apache and PHP 5, we have multiple Virtual Hosts with separate log files. We cannot seem to separate the php error_log
between virtual hosts.
在 httpd.conf
的
中覆盖此设置似乎没有任何作用.
Overriding this setting in the <Location>
of the httpd.conf
does not seem to do anything.
有没有办法为每个虚拟主机设置单独的 php error_logs
?
Is there a way to have separate php error_logs
for each Virtual Host?
推荐答案
要设置 Apache(不是 PHP)日志,最简单的方法是要做:
To set the Apache (not the PHP) log, the easiest way to do this would be to do:
<VirtualHost IP:Port>
# Stuff,
# More Stuff,
ErrorLog /path/where/you/want/the/error.log
</VirtualHost>
如果没有前导/",则假定是相对的.
If there is no leading "/" it is assumed to be relative.
这篇关于每个虚拟主机的 error_log?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文