zl程序教程

您现在的位置是:首页 >  其它

当前栏目

关于“Warning: DocumentRoot [/usr/local/apache2/docs/dummy-host.example.com] does not exist“

关于 not com does Host local exist WARNING
2023-09-14 09:05:18 时间

场景:早上开启虚拟机重启Apache的时候发生了 如下告警


Warning: DocumentRoot [/usr/local/apache2/docs/dummy-host.example.com] does not exist

Warning: DocumentRoot [/usr/local/apache2/docs/dummy-host2.example.com] does not exist

在网上查到的信息是,把httpd.conf中Include conf/extra/httpd-vhosts.conf的注释去掉会出现警告。

想了想,周一的时候 在虚拟机配置了 虚拟主机 [当时配置的贼鸡儿烦躁!]

在/usr/local/apache2/docs/目录下建了dummy-host.example.com和dummy-host2.example.com两个文件,重启Apache。还是同样的报警!

后来去conf/extra/httpd-vhosts.conf文件中才找到答案,原来应该在docs目录中建dummy-host.example.com和dummy-host2.example.com两个文件夹,然后重启Apache,就ok了。

解决了!NICE!