How To Fix “Apache2: Could Not Reliably Determine the Server’s FQDN”

1
What is Certificate Signing Request (CSR) and How to Generate CSR-techinfoBiT
Image Source: apache.org

If you are getting this error and worrying about what is this and why it’s coming then, the first thing you should know that this is just a friendly warning but it needs to be fixed to avoid the warning message each time you start the Apache. The Fully Qualified Domain Name or also known as FQDN is basically simply another name for the complete domain name for a specific computer, or host, on the Internet.

Wikipedia explains it as a domain name that specifies its exact location in the tree hierarchy of the Domain Name System or DNS.

You might be getting this error whenever you trying to restart Apache2 service using either one of these commands:

/etc/init.d/apache2 restart

Or

service apache2 restart

You will then get an error message:-

How To Fix "apache2: Could not reliably determine the server’s fully qualified domain name" - techinfoBiT

How To Fix FQDN Issue On Apache

Step 1: Login to your server via SSH. You can use either Putty on Windows or Terminal if you are on Mac or Linux. If you can, you better login as root or as a user with root privilege.

Step 2: Now issue following command syntax:

nano /etc/apache2/httpd.conf

Step 3: You’ll now in Nano text editor. If you see a blank screen, just don’t worry it is normal. Now type the following line in there.

ServerName localhost

Like this one:

How To Fix "Apache2: Could Not Reliably Determine the Server’s FQDN" - techinfoBiT

Once done, save it and exit. In Nano editor, the command to save should be Control+O while Control+X used to exit.

Step 4: Next, simply restart Apache2 service. There are two most common commands used to accomplish that task. You can use either.

/etc.init.d/apache2 restart

or

service apache2 restart

That’s it. Now you should see the error has gone.

How To Fix "Apache2: Could Not Reliably Determine the Server’s FQDN" - techinfoBiT

LEAVE A REPLY

Please enter your comment!
Please enter your name here


This site uses Akismet to reduce spam. Learn how your comment data is processed.