All tech and Linux blog, under the flag of open source world....

November 24, 2019

Changing mirrors in Fedora

You might have a problem with your package download speeds in fedora Linux but changing it is quiet easy, we will also show you a method of how to find the fastest one.

Fedora Linux 29
This guide will work on all recent Fedora versions. First head over to "etc/yum.repos.d" using gnome files, then right click on the empty section then choose open terminal. (you can do this directly with "cd /etc/yum.repos.d" command.)
Then choose a text editor, like vim or nano, and open fedora.repo using sudo. (sudo vim fedora.repo).
Now open your browser and use this link to go to fedora mirrors website, choose your version and find the mirror that you desire. (Select the one close to you that has a high bandwidth for a better speed.)
Click on Http link of the mirror that you have chosen.
Here I have selected RWTH Aachen mirror that is close to me and fast.
copy the link in the new opened page, now go back to your terminal.
In the terminal .
Here I'm editing fedora.repo in vim
Change the #baseurl  in the beginning, by pasting the mirror link. (make sure you don't remove  "$releasever" to the end of the link. because fedora finds the package file using the release version  and it also means you don't need to change your mirror when you update your fedora.)
paste your link and check if the sub directory looks similar to the previous one. then save this file. (in vim you should press Esc then type ":wq")
You can also edit the fedora-updates.repo by doing the same,  just make sure the ../updates/releasever... is included at the end. because this repo is for updates, we don't want to confuses it with the original mirror. Check your new mirrors now! :D
You can use this guide on any repository just make sure you backup.

For finding the fastest mirror

For finding the fastest mirror there are two options: 
  • Test each mirror by downloading a package from it for example I use my browser and download Apache server package and check the time it takes to download it in each mirror.
  • There is a tool here an app that does this for you, follow the guide in the README file there, also note that this is a BETA so backup your mirrors before doing anything.
Thanks to Fedora Community to make this guide happen.
Share:

0 comments:

Post a Comment

Labels