红联Linux门户
Linux帮助

ubuntu apache using 127.0.1.1. Set the 'ServerName'

发布时间:2017-05-03 10:11:10来源:linux网站作者:德星
运行sudo /etc/init.d/apache2 restart出现错误:
apache2:Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
ubuntu apache using 127.0.1.1. Set the 'ServerName'
 
解决办法:
sudo vim /etc/apache2/sites-available/default.conf (或者000-default.conf)
打开default文件后,在default文件顶端加入:
ServerName 127.0.0.1
sudo /etc/init.d/apache2 restart
重启apache2 就不会提示上述错误了。
 
本文永久更新地址:http://www.linuxdiyf.com/linux/30478.html