Plesk

/etc/resolv.conf does not hold changes on the server with Plesk

Symptoms

Cause

There are three known possible causes for this behavior:

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:

  1. Log into your server via SSH

  2. Edit the /etc/systemd/resolved.conf.

  3. 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

  4. 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

  5. Restart the systemd-resolved service by executing the following command:

    # systemctl restart systemd-resolved

  6. 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:

  1. Log into your server via SSH

  2. Execute the following command:

    # systemctl disable systemd-resolved && systemctl stop systemd-resolved

  3. 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

  4. 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

Exit mobile version