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

by | Jul 21, 2011 | Linux Administrator

Today, while performing some mainenance on one of my Debian GNU/Linux servers, I needed to restart Apache.

While logged in as the root user, I used the following command:

test:~# /etc/init.d/apache2 restart

When this command had finished running, I was presented with the following message:

Restarting web server: apache2apache2: Could not reliably determine the server's fully qualified domain name, using fu.bar.com for ServerName
[Thu Jul 21 09:40:00 2011] [warn] NameVirtualHost 10.0.0.1:80 has no VirtualHosts
... waiting apache2: Could not reliably determine the server's fully qualified domain name, using fu.bar.com for ServerName
[Thu Jul 21 09:40:00 2011] [warn] NameVirtualHost 10.0.0.1:80 has no VirtualHosts

What do you mean, could not reliably determine the server’s fully qualified domain name (FQDN)?

Well, it seems the default configuration of the /etc/apache2/httpd.conf file, is blank.

The fix, is just as easy.

In a Debian GNU/Linux terminal, logged in as the root user, type:

test:~# pico /etc/apache2/httpd.conf

then press the [enter] key. The pico editor will open the httpd.conf file.

In Kubuntu’s Konsole, type:

test:~# sudo pico /etc/apache2/httpd.conf

then press the [enter] key. The pico editor will open the httpd.conf file.

Simply add the following line to the httpd.conf file.

ServerName localhost

Save the file and restart Apache.

No more “Could not reliably determine the server’s fully qualified domain name” message.

Logo with image

About the Author:

WebDevRobert

Innovative Technology Professional, working on IT/OT Convergence & Security, in the foundry industry.

Website Designer/Developer since the mid 1990’s.

Apple, Linux and Network Administrator since the late 1990’s.

Background includes several years of IT/OT and IIoT Administration, Communications Infrastructure Design and Project Management.

Currently the VP of Technology for Oil City Iron Works, Inc., in Corsicana, TX.

Subscribe for Updates:

This field is for validation purposes and should be left unchanged.
This field is hidden when viewing the form

Next Steps: Sync an Email Add-On

To get the most out of your form, we suggest that you sync this form with an email add-on. To learn more about your email add-on options, visit the following page (https://www.gravityforms.com/the-8-best-email-plugins-for-wordpress-in-2020/). Important: Delete this tip before you publish the form.
Name(Required)
Email(Required)