Could not reliably determine the server's fully qualified domain name

mahesh picture mahesh · May 2, 2011 · Viewed 377.3k times · Source

I have just installed Apache 2.2.17, and I am using it first time.

Now when I try to start the server using the command service httpd start it gives me the message:

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

Now I think I have to set ServerName and the IP address as I search through Google. But I don't know in which file I have to set.

How can I fix this problem?

Answer

Douglas Miranda picture Douglas Miranda · Nov 22, 2011
  1. sudo vim /etc/apache2/httpd.conf
  2. Insert the following line at the httpd.conf: ServerName localhost
  3. Just restart the Apache: sudo /etc/init.d/apache2 restart