Linux Mint/Ubuntu: Apache2 Fully Qualified Name Error

Chances are that if you set up an Apache web server on Mint or Ubuntu, you will see this error:

“Could not reliably determine the server’s fully qualified domain name, using for ServerName”

There are a couple ways to do it, however I think this is the “right” way to do it. The other common way involves creating what is essentially the old configuration file and pointing the new file to it. This one just creates a file in conf.d which apache2 scans the entire contents of anyway upon start up.

Open the new file for editing, we are going to call it name here:

sudo vim /etc/apache2/apache2.conf

Type in the following (I chose the end of the file):

ServerName localhost

This is just fine for 99% of home users.

Restart Apache:

sudo service apache2 restart

Presto! No more error.