httpd.exe: Could not reliably determine the server’s fully qualified domain name
查看系统日志,看到这个错误:
httpd.exe: Could not reliably determine the server’s fully qualified domain name, using 192.168.1.xx for ServerName
虽然apache能正常运行,但是觉得不爽,查了一下原来是因为DNS没配置好。我们细看httpd.conf文件的时候,可以看到以下:
# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
#
#ServerName www.example.com:80
apache启动时可能会查询DNS来验证ServerName的配置,我们只要在httpd.conf文件加入 ServerName localhost:80 重启apache即可,localhost这里我们就填写自己服务器的IP地址。