How to use a direct mirror with DNF and avoid checking

My ISPs or my country’s Internet infrastructure seem to be blocking The IP address for this web address is not resolved in most networks in my country. Only via a VPN, can you update your Fedora workstation.
When I run a dnf update command, I often get an error related to not being able to access

The specific mirrors do not have a problem most often. So, my question is “How can I stop Fedora from checking” each time I invoke an update? How can I pass a direct mirror to the DNF command or configure in its settings, so that updates can be done full-speed without a VPN?

In the repo configs in /etc/yum.repos.d/ you can use baseurl and specify a server instead of using metalink pointing to the mirror server. Use ‘#’ to comment the metalink lines and remove ‘#’ in front of baseurl.

1 Like

There are a lot of config files in the mentioned directory. I prefer not to do manual changes in every file. Is there a command switch or a global configuration available?