Affected versions: Ubuntu 26.04 LTS

📖 ~1 min read

Table of contents
  1. Symptom & Impact
  2. Environment & Reproduction
  3. Root Cause Analysis
  4. Quick Triage
  5. Step-by-Step Diagnosis
  6. Solution – Primary Fix
  7. Solution – Alternative Approaches
  8. Verification & Acceptance Criteria
  9. Rollback Plan
  10. Prevention & Hardening
  11. Related Errors & Cross-Refs
  12. References & Further Reading

Symptom & Impact

Package metadata cannot be downloaded because repository hostnames do not resolve.

Environment & Reproduction

Typically seen after network changes or resolver misconfiguration.

sudo apt update

Root Cause Analysis

systemd-resolved or upstream DNS servers are unavailable or misconfigured.

Quick Triage

Test name resolution and current DNS server assignments.

resolvectl status
getent hosts archive.ubuntu.com

Step-by-Step Diagnosis

Check resolver service logs and network routing state.

sudo systemctl status systemd-resolved
ip route
sudo journalctl -u systemd-resolved -n 80
Illustrative mockup for ubuntu-26-04-lts — dns_diag
DNS failures impacting apt — Illustrative mockup — Progressive Robot

Solution – Primary Fix

Set valid DNS servers in netplan or NetworkManager and reapply network settings.

Still having issues? Our IT Solutions & Services team can diagnose and resolve this for you. Get in touch for a free consultation.

sudo netplan apply
resolvectl flush-caches
sudo apt update
Illustrative mockup for ubuntu-26-04-lts — dns_fix
Resolved DNS configuration via systemd-resolved — Illustrative mockup — Progressive Robot

Solution – Alternative Approaches

Use temporary resolver override for maintenance tasks.

sudo resolvectl dns  1.1.1.1 8.8.8.8

Verification & Acceptance Criteria

Repository hostnames resolve and apt update succeeds.

getent hosts security.ubuntu.com
sudo apt update

Rollback Plan

Revert netplan changes to previous known-good configuration and reapply.

sudo netplan apply

Prevention & Hardening

Monitor DNS health and keep redundant resolvers configured for critical hosts.

Frequently linked with proxy failures, route loss, and intermittent packet loss.

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

Ubuntu netplan and systemd-resolved operations guide.

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.