在Ubuntu上装完Apache后,每次启动apache服务器都会得到如下警告:
apache2: Could not reliably determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName
解决办法也很简单:
sudo echo ServerName localhost >> /etc/apache2/httpd.conf
或者
sudo echo ServerName localhost >> /etc/apache2/httpd.conf
或者
sudo gedit /etc/apache2/httpd.conf
在里面加上一行:
ServerName localhost
注意httpd.conf默认是个空文件
没有评论:
发表评论