错误未写入Apache错误日志

 会丶有那么一天 发布于 2023-02-11 19:24

我遇到了一些Apache Web服务器错误日志的问题。

我的计算机上有一个虚拟托管的网站scotthermmann.loc。在我手动清除错误日志后,使用

sudo cat /dev/null > scotthermmann.loc-error_log

或者通过在emacs中打开文件并删除所有内容,错误将不再记录到文件中。我试过使用

sudo apachectl restart

解决问题,但不能解决。注销并重新登录也无法解决。解决问题的方法是重新启动计算机,但是每次清除错误日志后,我都不想这样做。

我托管的每个网站都并非如此。我有另一个网站nudefootfool.loc。清除错误日志后,我没有任何问题。

两个虚拟站点在httpd-vhosts.conf文件中的设置基本相同。对于scottherrmann.loc:


    DocumentRoot "/Users/dan/Sites/scottherrmann.com"
    ServerName scottherrmann.loc
    ServerAlias www.scottherrmann.loc
    ErrorLog "/private/var/log/apache2/scottherrmann.loc-error_log"
    CustomLog "/private/var/log/apache2/scottherrmann.loc-access_log"

    
        Options Indexes FollowSymLinks
        AllowOverride All
        Order Allow,Deny
        Allow from all 
    

而对于footfootfool.loc:


    DocumentRoot "/Users/dan/Sites/barefootfool.com"
    ServerName barefootfool.loc
    ServerAlias www.barefootfool.loc
    ErrorLog "/private/var/log/apache2/barefootfool.loc-error_log"
    CustomLog "/private/var/log/apache2/barefootfool.loc-access_log"

    
        Options Indexes FollowSymLinks
        AllowOverride All
        Order Allow,Deny
        Allow from all 
    

有谁知道是什么原因引起的问题?

撰写答案
今天,你开发时遇到什么问题呢?
立即提问
热门标签
PHP1.CN | 中国最专业的PHP中文社区 | PNG素材下载 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有