Bug 1289010 - dnf fails to try other mirrors when one mirror fails
dnf fails to try other mirrors when one mirror fails
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: dnf (Show other bugs)
22
x86_64 Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: packaging-team-maint
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-12-07 03:45 EST by Josh Chia
Modified: 2015-12-15 07:02 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-12-15 07:02:21 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
fedora-updates.repo (1.32 KB, text/plain)
2015-12-10 17:46 EST, Josh Chia
no flags Details

  None (edit)
Description Josh Chia 2015-12-07 03:45:58 EST
Description of problem:
I have two baseurl entries in my fedora.repo & fedora-updates.repo, in the fedora and updates sections respectively, one for download.fedoraproject.org and another for mirrors.ustc.edu.cn, no metalink. When I dnf clean all and then dnf update, I get an error, but if I comment out the mirrors.ustc.edu.cn in the fedora-updates.repo, there is no error.

If the failure is due to the mirrors.ustc.edu.cn being in the bad state, dnf client should try a good mirror instead of just failing.


Version-Release number of selected component (if applicable):
$ rpm -qa |grep -i dnf
python-dnf-1.1.4-2.fc22.noarch
dnf-yum-1.1.4-2.fc22.noarch
dnf-1.1.4-2.fc22.noarch
dnf-plugins-core-0.1.14-1.fc22.noarch
dnf-conf-1.1.4-2.fc22.noarch
python-dnf-plugins-core-0.1.14-1.fc22.noarch

Steps to Reproduce:
1. Edit the two repo files to have those two baseurls and no metalink
2. dnf clean all
3. dnf update
4. Get an error.
5. Comment out the mirrors.ustc.edu.cn baseurl from fedora-updates.repo
6. Repeat 2-3 and see success.

Actual results:
Fedora 22 - x86_64                                                                                                                                                                                                                                                                           6.8 MB/s |  41 MB     00:06
Error: Failed to synchronize cache for repo 'updates' from 'http://mirrors.ustc.edu.cn/fedora/linux/updates/22/x86_64/': Yum repo downloading error: Downloading error(s): repodata/3557cd282ff3a9ed489b9a469bd9ca23771fb67d01d6121e8e889417d57b51ee-filelists.xml.gz - Cannot download, all mirrors were already tried without success; repodata/3b28448c0858d4aeef04a14167f9193ea3d5231e2bc017313087f192f027c906-prestodelta.xml.xz - Cannot download, all mirrors were already tried without success; repodata/e825b219e5e1e2f55c25abe11776abf557405dd48be8bc95b8d4a80f9b90db4a-primary.xml.gz - Cannot download, all mirrors were already tried without success; repodata/59e80bc0f0034efdcd6464af8c420174e5f64663f6c339c452123f719b742326-updateinfo.xml.xz - Cannot download, all mirrors were already tried without success


Expected results:
dnf update succeeds, even if mirrors.ustc.edu.cn is in a bad state but download.fedoraproject.org is in a good state.

When I did the experiment, commenting out mirrors.ustc.edu.cn caused dnf update to succeed, so dnf update is applying faulting logic for failover to a good mirror (download.fedoraproject.org).
Comment 1 Josh Chia 2015-12-07 03:47:50 EST
As of this writing, the contents of http://mirrors.ustc.edu.cn/fedora/linux/updates/22/x86_64/repodata/:
02de6198cf72db215a1f0102f86454c5da08d0d9312844e..> 06-Dec-2015 02:56              235480
87264b87ffa673b5ec89e25bc8481723c7df65a28399de1..> 06-Dec-2015 02:56             1722592
repomd.xml                                         06-Dec-2015 02:56                4848
Comment 2 Jaroslav Mracek 2015-12-10 10:20:11 EST
I am sorry, but I cannot reproduce it. Please could you provide .repo file that caused a problem, and repo file that working correctly. Thanks a lot.
Comment 3 Josh Chia 2015-12-10 17:46 EST
Created attachment 1104512 [details]
fedora-updates.repo

This config didn't work earlier. After I commented out the ustc.edu.cn line, the problem went away.
Comment 4 Josh Chia 2015-12-10 17:50:30 EST
Sorry, I think I gave some confusing info earlier, so I've attached the actual config file.

The problem is dependent on the state of the mirrors. I can't repro it now, but the point is that if ustc.edu.cn was failing, it seems that dnf should have just failed over to the metalink.
Comment 5 Jaroslav Mracek 2015-12-14 07:52:44 EST
Thank you very much for your information. We think that yours problem was that originally you had two times baseurl= and it is a problem. If you have two links, uou have to make baseurl=URL1,URL2 .
We hope that it helps
Comment 6 Josh Chia 2015-12-15 06:23:21 EST
No, the fedoraproject.org baseurl is always commented out. You can treat the .repo file I submitted as not having that line at all. The baseurl line in question is the one for ustc.edu.cn. Without commenting out that line, dnf failed. With that line commented out, dnf succeeded.
Comment 7 Josh Chia 2015-12-15 07:02:55 EST
Ignore last comment. I typed too fast.

Note You need to log in before you can comment on or make changes to this bug.