Optimize your Linux system's update and download speeds by choosing the best mirrors
Mirrors are servers that host copies of a distribution's software repositories. Choosing a fast and reliable mirror can significantly improve your system's update and download speeds. This guide will help you understand, select, and use the best mirrors for your Linux system.
Use the built-in mirror selection tool:
sudo software-properties-gtk
Or use the command-line tool:
sudo apt install python3-launchpad-integrationsudo python3 /usr/lib/python3/dist-packages/softwareproperties/gtk/SoftwarePropertiesGtk.py
Fedora automatically selects the fastest mirror by default. To manually select:
sudo dnf config-manager --set-enabled fedora-fastest-mirror
Use the Reflector tool:
sudo pacman -S reflectorsudo reflector --country 'United States' --age 12 --protocol https --sort rate --save /etc/pacman.d/mirrorlist
ping or curlConsider using a mirror speed test script to automate the process of finding the fastest mirrors. Many distributions offer these scripts in their repositories.
| Distribution | Mirror List Location | Update Command |
|---|---|---|
| Ubuntu/Debian | /etc/apt/sources.list | sudo apt update |
| Fedora | /etc/yum.repos.d/ | sudo dnf clean all && sudo dnf makecache |
| Arch Linux | /etc/pacman.d/mirrorlist | sudo pacman -Syy |
While faster mirrors can significantly improve your system's performance, always prioritize reliability and security. A slightly slower but more stable mirror is often preferable to a faster but less reliable one.