Resolving "AH00558: Could not reliably determine the server's fully qualified domain name"
The Apache AH00558: Could not reliably determine the server's fully qualified domain name
message is generated when Apache is not configured with a global ServerName
directive. This is he message is mainly for informational purposes, and an AH00558 error will not prevent Apache from running correctly.
$ sudo apache2ctl configtest AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message Syntax OK
Likewise, when restarting the Apache service, we can also get the same error:
$ sudo systemctl restart apache2 AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
The simplest method to resolve this message is to set the ServerName
in the correct Apache configuration file. The table below lists some of the locations that I have amended to make these changes across various platforms:
OS | Apache Version | File location / Action |
---|---|---|
Solaris 9 | 1.3x |
|
Ubuntu 13.04 Ubuntu 13.10 Ubuntu 16.04 |
2.4 |
|
Fedora 12 | -- |
|
Debian 10 Ubuntu 18.04 |
2.4.10 |
|
macOS | -- |
|
* Replace YourDomain.com with your actual FQDN of your webserver.