📖 ~1 min read
Table of contents
Symptom & Impact
`dnf makecache` and package installs fail with timeout or mirror errors, delaying patching and security updates.
Environment & Reproduction
On RHEL 8 hosts behind strict egress rules, run `dnf makecache` and observe repeated download retries.
Root Cause Analysis
Common causes include DNS latency, blocked proxy paths, stale repo definitions, or unreachable mirrorlist endpoints.
Quick Triage
Check connectivity with `curl -I` to repo URLs and validate resolver health before changing repository settings.
Step-by-Step Diagnosis
Run `dnf repolist -v`, inspect `/etc/yum.repos.d/*.repo`, test `dig` and `ping` to mirror hosts, then review `journalctl -u NetworkManager`.

Solution – Primary Fix
Set valid `baseurl`, configure proxy if required, then run `dnf clean all && dnf makecache` and verify repository metadata downloads complete.
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 internal Satellite or local mirror, pin a stable mirror, or schedule retries during low network contention windows.
Verification & Acceptance Criteria
`dnf updateinfo list` and `dnf upgrade –assumeno` should complete without timeout, and no repo errors should remain.
Rollback Plan
Restore previous `.repo` files from backup and revert proxy changes if package source validation fails.
Prevention & Hardening
Monitor repo latency, standardize repo templates via automation, and alert on repeated `dnf` failures in logs.
Related Errors & Cross-Refs
`Cannot prepare internal mirrorlist`, `All mirrors were tried`, and TLS handshake failures to CDN endpoints.
Related tutorial: View the step-by-step tutorial for rhel-8.
View all rhel-8 tutorials on the Tutorials Hub →
Browse all common problems & solutions on the Tutorials Hub.
References & Further Reading
RHEL 8 package management docs, `dnf.conf(5)`, and enterprise proxy guidance for Red Hat repositories.
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.