New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not using downloaded repomd.xml because it is older than what we have #96
Comments
I dunno, seems kind of like a real corner case; if you do this "repointing" (presumably with Chef), wouldn't you do a
|
Don't get me wrong, this seems like dumb yum behavior. Ideally yum would provide a flag ( Just to be clear, I'm not advocating calling For what it's worth, I just did the following test and confirmed that it works:
|
A colleague of mine just pointed out that we actually can't trigger a |
what is the lightest test you can think of to detect this condition? |
I figured out how we're hitting this bug and I've got a simple-ish test case. Basically we've got a race condition between our local yum repos and the upstream yum repos. Our workflow is that we automatically provision a hardware appliance with cobbler, reboot, run the first run setup to set hostname (as we use chef vault and have to have our node registered with a known name) and then reboot and bootstrap the chef client. When we run our chef converge, usually within five to ten minutes from when the appliance was first provisioned, our cookbook changes the location of the repositories to our local mirrors and sometimes those mirrors are behind the upstream yum repositories by up to an hour. |
It's been a while since I've looked at this, but to summarize my comments above, I believe the solution is to run |
@someara I don't think this is something you'd want to "detect" per-se. What I'm suggesting is that the |
I've added a "yum clean" before the "yum makecache" in the :create action. |
👍 |
Awesome! Thanks @someara! |
I'm setting this on oracle linux 6.5, chef 12.4.1 |
yum makecache
fails inside theyum_repository
provider when you point to a mirror with an olderrepomd.xml
than what has already been downloaded. This could happen if you start out pointing to an official mirror, then reconfigure yum to point to your own local mirror (which may not have had a chance to sync up yet):I think the solution is to run a
yum clean
before runningyum makecache
. Unless there's some flag I'm missing to force yum to use the older repomd.xml.The text was updated successfully, but these errors were encountered: