Skip to content

Detect systemd-resolved in stub mode

This commit fixes systemd-resolved detection for its currently recommended mode of operation. In this mode systemd-resolved operates as stub DNS server at 127.0.0.53 and names itself as nameserver in /etc/resolv.conf for backwards compatibility. Therefore systemd-resolved should also be considered active if the hosts line in /etc/nsswitch.conf only lists 'dns', but /etc/resolv.conf is a symlink to a systemd-resolved managed stub-resolv.conf

For further information see: https://www.freedesktop.org/software/systemd/man/systemd-resolved.service.html#/etc/resolv.conf

Merge request reports