Reaching out to others! Free & Open Source Software, Kannada, L10n, L18n Data Science, Cloud Computing & more…

Plesk/HSPComplete Fix: Unable to resolve hostname

General, linux, Plesk, QuickFix, Technical | 0 comments

Dig and ping fails on the server though network configuration is found to be fine. No iptables or other firewalls installed on the server.You might face this issue even during the Plesk installation / re-installation.

Resolution :
To fix it you should specify full hostname of the server in the form of “hostname.domain.tld” instead of just “hostname”. Also you should be able to ping the server by hostname. Please follow these steps to resolve this original issue:

1) Run the command below to specify a new hostname of the server. For example it will be “plesk.yourdomain.com”:
# hostname plesk.yourdomain.com

2) Add the following line to the /etc/hosts file, when ip.address is a real IP address of the server:

ip.address.of.your.server plesk.yourdomain.com plesk

3) Change the following variable in the /etc/sysconfig/network file:

HOSTNAME=plesk.yourdomain.com

4) Restart network service
# /etc/init.d/network restart

5) Please make sure that you are able to ping the server by the new hostname:
# ping plesk.yourdomain.com

You should get the following output of ping command:

PING plesk.yourdomain.com (192.168.45.8) 56(84) bytes of data.
64 bytes from plesk.yourdomain.com (192.168.45.8): icmp_seq=1 ttl=64 time=0.086 ms
64 bytes from plesk.yourdomain.com (192.168.45.8): icmp_seq=1 ttl=64 time=0.086 ms
64 bytes from plesk.yourdomain.com (192.168.45.8): icmp_seq=1 ttl=64 time=0.086 ms

6) If ping doesn’t work be sure that ICMP ECHO packets are allowed with:

# /sbin/sysctl net.ipv4.icmp_echo_ignore_all
net.ipv4.icmp_echo_ignore_all = 0

If the server is still not accessible by the hostname then please make sure that firewall is not enabled. In this case you need to turn off any firewall on the server.

Source: https://kb.parallels.com

Related Articles

Related