CentOS 8.x DNS resolution issues when there is proper working DNS in /etc/resolv.conf

From Notes_Wiki
Revision as of 07:20, 14 April 2021 by Saurabh (talk | contribs) (Created page with "<yambe:breadcrumb self="DNS resolution issues when there is proper working DNS in /etc/resolv.conf">CentOS 8.x systemd or systemctl|systemd or systemctl</yambe:breadcrumb> =Ce...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

<yambe:breadcrumb self="DNS resolution issues when there is proper working DNS in /etc/resolv.conf">CentOS 8.x systemd or systemctl|systemd or systemctl</yambe:breadcrumb>

CentOS 8.x DNS resolution issues when there is proper working DNS in /etc/resolv.conf

While using CentOS 8.x Stream it is possible to get DNS resolution errors via applications such as postfix, even when there is properly working DNS in /etc/resolv.conf and ping / nslookup / dig etc. are working properly. In this case try:

systemd-resolve --status

If it shows error such as:

Failed to get global data: Unit dbus-org.freedesktop.resolve1.service not found

then use following steps to resolve the issue:

  1. Create file named "/etc/NetworkManager/conf.d/no-systemd-resolved.conf" with
    [main]
    systemd-resolved=false
  2. Also use:
    systemctl enable systemd-resolved.service
    systemctl start systemd-resolved.service
    systemctl status systemd-resolved.service
  3. After this again test
    systemd-resolve --status
    and validate that systemd-resolve is working properly.


Refer:



<yambe:breadcrumb self="DNS resolution issues when there is proper working DNS in /etc/resolv.conf">CentOS 8.x systemd or systemctl|systemd or systemctl</yambe:breadcrumb>