cf435e6c2a
The 'yum makecache' step is failing. The issue is seen when the fast mirror plugin for yum is in use (default). The metadata for a yum repo as scattered across several files. The master file is repomd.xml, and it may list several supporting files, e.g. filelists.xml.gz primary.xml.gz filelists.sqlite.bz2 other.sqlite.bz2 other.xml.gz primary.sqlite.bz2 When fast mirror plugin is in use, each file might download from a separate source. This opens the door for a race condition when a repo update is rolling out across the mirrors. The error suggests we have already downloaded a repomd.xml, but it is obsolete and references a supporting file that no longer exists. A second possible source of inconsistent data is caching proxies. Solution: 1) Disabling the yum fast cache plugin is undesirable, and there is no option forcing metadata iof a given repo to be single sourced. So this update adds a limited number of retries for the 'yum makecache' command. So far we've never seen 'yum makecache' fail twice in a row... largely because the 'fastest mirror' plugin rarely downloaded from the same source twice. 2) Add 'http_caching=packages' to yum.conf, which asks upstream proxies to not cache repodata. Change-Id: I3fa3f61e38d868fb14f4175b87c0d323abb57def Closes-bug: 1818911 Signed-off-by: Scott Little <scott.little@windriver.com>
44 lines
1.5 KiB
Plaintext
44 lines
1.5 KiB
Plaintext
[main]
|
|
releasever=7
|
|
cachedir=/tmp/cache/yum/$basearch/$releasever
|
|
keepcache=0
|
|
debuglevel=2
|
|
logfile=/tmp/log/yum.log
|
|
exactarch=1
|
|
obsoletes=1
|
|
gpgcheck=1
|
|
plugins=1
|
|
installonly_limit=5
|
|
bugtracker_url=http://bugs.centos.org/set_project.php?project_id=23&ref=http://bugs.centos.org/bug_report_page.php?category=yum
|
|
distroverpkg=centos-release
|
|
override_install_langs=en_US.utf8
|
|
tsflags=nodocs
|
|
http_caching=packages
|
|
reposdir=yum.repos.d
|
|
|
|
|
|
# This is the default, if you make this bigger yum won't see if the metadata
|
|
# is newer on the remote and so you'll "gain" the bandwidth of not having to
|
|
# download the new metadata and "pay" for it by yum not having correct
|
|
# information.
|
|
# It is esp. important, to have correct metadata, for distributions like
|
|
# Fedora which don't keep old packages around. If you don't like this checking
|
|
# interrupting your command line usage, it's much better to have something
|
|
# manually check the metadata once an hour (yum-updatesd will do this).
|
|
# metadata_expire=90m
|
|
|
|
# PUT YOUR REPOS HERE OR IN separate files named file.repo
|
|
# in /etc/yum.repos.d
|
|
#####
|
|
# CentOS-Base.repo
|
|
#
|
|
# The mirror system uses the connecting IP address of the client and the
|
|
# update status of each mirror to pick mirrors that are updated to and
|
|
# geographically close to the client. You should use this for CentOS updates
|
|
# unless you are manually picking other mirrors.
|
|
#
|
|
# If the mirrorlist= does not work for you, as a fall back you can try the
|
|
# remarked out baseurl= line instead.
|
|
#
|
|
#
|