首页 > Web开发 > 详细

httpd: Could not reliably determine the server's fully qualified domain name, using ::1 for ServerName

时间:2017-11-20 23:53:14      阅读:786      评论:0      收藏:0      [点我收藏+]

问题原因:

  httpd服务配置文件,并没有设置解析根地址,无法可靠地确定服务器的完全合格的域名

如何解决?

  httpd的配置文件放在 /etc/httpd/conf/目录下,去掉ServerName注释,并把www.example.com:80替换成 127.0.0.1:80

  cat httpd.conf |grep ‘ServerName‘                                        # 查询域名设置
  sed ‘s@#ServerName www.example.com:80@ServerName 127.0.0.1:80@g‘ httpd.conf |grep ‘ServerName‘     # 预替换,并查看结果
  sed -i ‘s@#ServerName www.example.com:80@ServerName 127.0.0.1:80@g‘ httpd.conf |grep ‘ServerName‘   # 替换
  cat httpd.conf |grep ‘ServerName‘                                        # 查询替换后结果

  

 

 

  

httpd: Could not reliably determine the server's fully qualified domain name, using ::1 for ServerName

原文:http://www.cnblogs.com/2bjiujiu/p/7868650.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!