Symptoms
-
System overwrites the changes in the
/etc/resolv.conf
file -
The file
/etc/resolv.conf
contains the following warning:# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "resolvectl status" to see details about the actual nameservers.
nameserver 127.0.0.53 -
Plesk is unable to resolve external hosts, separate DNS zones of domains or separate DNS records within the DNS zones of domains
Cause
There are three known possible causes for this behavior:
- NetworkManager is used
-
systemd-resolved
overwrites the changes in the/etc/resolv.conf
file - Custom DNS resolvers are used and they are unable to resolve certain domains for unknown reasons
Resolution
Warning: Since /etc/resolv.conf
and /etc/systemd/resolved.conf
contents are not part of the Plesk configuration and are to be selected by the server or network administrator, it is highly recommended to contact the administrator of your network service before performing any of the operations listed below.
Apply one of the following solutions:
Make adjustments in the /etc/systemd/resolved.conf
file by following these steps:
-
Log into your server via SSH
-
Edit the
/etc/systemd/resolved.conf
. -
Add at least one reliable open DNS resolver such as
8.8.8.8
,8.8.4.4
(Google),1.1.1.1
,1.0.0.1
(Cloudflare) to the beginning of the list -
Save the changes
For example, the adjusted/etc/systemd/resolved.conf
file would have the following content:[Resolve]
DNS=8.8.8.8 203.0.113.2 203.0.113.3 -
Restart the
systemd-resolved
service by executing the following command:# systemctl restart systemd-resolved
-
Run the following command in order to confirm that the changes have been applied:
# resolvectl status
If you see the newly added DNS resolver to the list of results, you have been successful.
Consult with your network administrator if `systemd-resolved` can be disabled by following these steps:
-
Log into your server via SSH
-
Execute the following command:
# systemctl disable systemd-resolved && systemctl stop systemd-resolved
-
Configure the DNS resolvers you would like to use directly in the
/etc/resolv.conf
file, Vi editor can be used for this.Note: Make sure to add at least one reliable open DNS resolver such
8.8.8.8
,8.8.4.4
(Google),1.1.1.1
,1.0.0.1
(Cloudflare) to the beginning of the list -
Save the changes
For example, the adjusted/etc/resolv.conf
file would have the following content:nameserver 8.8.8.8
nameserver 203.0.113.2
nameserver 203.0.113.3