π ~1 min read
Table of contents
Symptom & Impact
Hostnames fail intermittently while raw IP connectivity works, disrupting apt and service discovery.
Environment & Reproduction
Seen with VPN clients, split DNS, or stale upstream resolver assignments via DHCP/netplan.
Root Cause Analysis
Inconsistent upstream DNS, stub resolver conflicts, or broken `/etc/resolv.conf` symlink to systemd-resolved stub.
Quick Triage
Validate resolver service health before changing firewall or routing rules.
Step-by-Step Diagnosis
Run `resolvectl status`, check `/etc/resolv.conf` target, and inspect `journalctl -u systemd-resolved -n 200`.

Solution – Primary Fix
Set reliable DNS in netplan, restart `systemd-resolved`, and ensure `/etc/resolv.conf` points to stub or desired managed file.
Still having issues? Our IT Solutions & Services team can diagnose and resolve this for you. Get in touch for a free consultation.

Solution – Alternative Approaches
Use local caching resolver or per-link DNS policies when split-horizon requirements exist.
Verification & Acceptance Criteria
`resolvectl query` resolves consistently and apt/network services no longer hit transient DNS failures.
Rollback Plan
Restore prior resolver config backup and restart resolved service.
Prevention & Hardening
Document DNS ownership between VPN, netplan, and NetworkManager; monitor resolver error rate.
Related Errors & Cross-Refs
`Temporary failure resolving`, timeout to upstream DNS, and VPN split DNS leaks.
Related tutorial: View the step-by-step tutorial for Ubuntu 26.04 LTS.
View all Ubuntu 26.04 LTS tutorials on the Tutorials Hub β
Browse all common problems & solutions on the Tutorials Hub.
References & Further Reading
`man resolvectl`, systemd-resolved docs, and Ubuntu DNS troubleshooting guides.
Need Expert Help?
If you cannot resolve this yourself, our team offers hands-on Server Management, Managed IT Services, and flexible Support Plans. Contact us today β we respond within one business day.