📖 ~1 min read
Table of contents
Symptom & Impact
Hostname lookups fail intermittently, affecting updates and service discovery.
Environment & Reproduction
Common after VPN profile changes or DHCP option drift.
resolvectl query archive.ubuntu.com
Root Cause Analysis
Resolver receives invalid upstream DNS or stale per-link domain settings.
Quick Triage
Check resolver symlink and service status.
ls -l /etc/resolv.conf && systemctl status systemd-resolved
Step-by-Step Diagnosis
Inspect per-interface DNS servers and search domains.
resolvectl status

Solution – Primary Fix
Restore stub resolv.conf symlink and restart resolved.
Still having issues? Our IT Solutions & Services team can diagnose and resolve this for you. Get in touch for a free consultation.
sudo ln -sf /run/systemd/resolve/stub-resolv.conf /etc/resolv.conf && sudo systemctl restart systemd-resolved

Solution – Alternative Approaches
Define explicit DNS settings in netplan or NetworkManager profiles.
Verification & Acceptance Criteria
`resolvectl query` and `dig` succeed consistently for required domains.
Rollback Plan
Revert symlink and DNS profile changes if internal resolution breaks.
Prevention & Hardening
Monitor DNS health and enforce approved resolver ordering.
Related Errors & Cross-Refs
Related to DNSSEC failures and search-domain recursion loops.
Related tutorial: View the step-by-step tutorial for Ubuntu 24.04 LTS.
View all Ubuntu 24.04 LTS tutorials on the Tutorials Hub →
Browse all common problems & solutions on the Tutorials Hub.
References & Further Reading
Ubuntu systemd-resolved deployment and troubleshooting docs.
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.