There are multiple options, you can hard code it (/etc/yum.repos.d/fedora.repo
) or using fastmirror
.
In order to use fastmirror
you must first activate it:
in /etc/dnf/dnf.conf
add fastestmirror=true
then using this command dnf config-manager --add-repo
add the mirror you want to use, you can add multiple mirrors and the fastest one will be used.
Example:
sudo dnf config-manager --add-repo http://ftp.byfly.by/pub/fedoraproject.org/linux/releases/23/Everything/x86_64/os/
You must use the path /linux/releases/23/Everything/x86_64/os/
for fedora 23 releases and for fedora 23 updates /linux/updates/23/x86_64/
otherwise will not work.