Applicable to:
- Plesk for Linux
Symptoms
-
Apache fails to start. One of the following error messages appears in the Apache error log file:
-
on CentOS/RHEL-based distributions:
/var/log/httpd/error_log
-
on Debian/Ubuntu-based distributions:
/var/log/apache2/error.log
CONFIG_TEXT: (EAI 2)Name or service not known: AH01564: unable to find IPv4 address of "server.example.com"
AH00016: Configuration Failed
CONFIG_TEXT: (EAI 3)Temporary failure in name resolution: AH01564: unable to find IPv4 address of "ip-203-0-113-2"
AH00016: Configuration Failed -
-
The following email notification might be sent to Plesk administrator:
CONFIG_TEXT: Unable to generate the web server configuration file on the host <server.example.com> because of the following errors: Template_Exception: Can not restart web server: file: /opt/psa/admin/plib/Service/Driver/Web/Server/Apache.php line: 109 code: 0
CONFIG_TEXT: Unable to generate the web server configuration file on the host <server-hostname> because of the following errors:
Template_Exception: Can not restart web server: Apache is down, start it instead of graceful Apache is down, start it instead of graceful
Cause
There is no IPv4 address specified in the /etc/hosts
file for the server name configured in /etc/hostname
file.
Resolution
-
Go to Tools & Settings > Server Settings.
-
In the Full hostname field, set the server hostname.
-
Click OK.
-
Go to Tools & Settings > Services Management and make sure Web Server (Apache) is started.
-
Connect to the Plesk server via SSH.
-
Open the file
/etc/hosts
in a text editor. In this example, we are using the vi editor:# vi /etc/hosts
-
Add a valid <IPv4 hostname> configuration:, for example:
CONFIG_TEXT: 203.0.113.2 server.example.com
- Server hostname can be edited in the file
/etc/hostname
or can be found with the commandhostname
.
- Server hostname can be edited in the file
-
Reboot the server.
-
Verify that Apache has been started:
-
on CentOS/RHEL-based distributions:
# service httpd status
-
on Debian/Ubuntu-based distributions:
# service apache2 status
-
Comments
0 comments
Please sign in to leave a comment.