Feature #2866
Yum package provider does not allow downgrade
| Status: | Closed | Start date: | 11/26/2009 | ||
|---|---|---|---|---|---|
| Priority: | Normal | Due date: | |||
| Assignee: | - | % Done: | 20% |
||
| Category: | package | ||||
| Target version: | 2.7.0 | ||||
| Affected Puppet version: | development | Branch: | http://github.com/mmrobins/puppet/tree/ticket/2.6.x/2866 | ||
| Keywords: | |||||
| Votes: | 4 |
Description
After installing (e.g. by hand) a version of a package later than specified in the “ensure” attribute the yum provider refuses to downgrade the package:
change from 2.5.6-39.g120eba4 to 2.5.6-38.g01d82ad failed: Could not update: Failed to update to version 2.5.6-38.g01d82ad, got version 2.5.6-39.g120eba4 instead
Running “yum downgrade foo-2.5.6-38.g01d82ad” properly downgrades the package, but puppet always calls “yum install”.
Related issues
History
Updated by Grzegorz Nosek over 2 years ago
- File puppet-yum-downgrade.diff added
- % Done changed from 0 to 20
As a quick fix, I’m using the attached patch. Apparently works but as you can see, there are no tests etc.
Updated by James Turnbull over 2 years ago
- Category set to package
- Status changed from Unreviewed to Needs Decision
Updated by Luke Kanies over 2 years ago
- Status changed from Needs Decision to Accepted
- Target version set to 2.6.0
Updated by Luke Kanies over 2 years ago
- Status changed from Accepted to Tests Insufficient
Updated by Jesse Wolfe almost 2 years ago
- Target version changed from 2.6.0 to 52
Updated by Oliver Hookins almost 2 years ago
What kind of tests are required? If there is a document in the wiki describing testing standards please link to it, as I would find this functionality useful and wouldn’t mind spending a bit of time getting the patch up to standards for inclusion.
Updated by James Turnbull almost 2 years ago
Sorry Oliver – missed your question – see:
http://projects.puppetlabs.com/projects/puppet/wiki/Development_Lifecycle
and
http://projects.puppetlabs.com/projects/puppet/wiki/Development_Writing_Tests
Also the best model is to follow the existing tests for various package providers.
Updated by Dan Bode over 1 year ago
- Status changed from Tests Insufficient to Merged - Pending Release
- Branch set to http://github.com/bodepd/puppet/tree/ticket/2.6.1rc3/2866
Updated by Matt Robinson over 1 year ago
- Status changed from Merged - Pending Release to In Topic Branch Pending Review
- Branch changed from http://github.com/bodepd/puppet/tree/ticket/2.6.1rc3/2866 to http://github.com/mmrobins/puppet/tree/ticket/2.6.x/2866
My branch has some test changes that I recommended to Dan when I reviewed his patch on the mailing list. I’d consider this ready for checking with a +1 from me, but I’ll resend it to the list just in case.
Updated by Matt Robinson over 1 year ago
- Status changed from In Topic Branch Pending Review to Ready For Checkin
- Assignee set to Markus Roberts
I didn’t hear any complaints on the list, and I’ve +1’d with the changes I suggested included. My branch is against 2.6.x, but I’ll let Markus determine if it belongs in 2.6 or later. If you need me to rebase let me know.
Updated by James Turnbull over 1 year ago
- Target version changed from 52 to 2.6.3
Updated by James Turnbull over 1 year ago
- Target version changed from 2.6.3 to 2.7.x
Updated by Matt Robinson over 1 year ago
- Status changed from Ready For Checkin to Merged - Pending Release
- Assignee deleted (
Markus Roberts) - Affected Puppet version changed from 0.24.8 to development
commit:e00c582c8977a02200b86f18ccc6debf30abdfed
Updated by Nick Lewis over 1 year ago
- Status changed from Merged - Pending Release to Closed
Updated by James Turnbull 11 months ago
- Target version changed from 2.7.x to 2.7.0
Updated by John DeStefano 6 months ago
If this truly has been fixed/closed in 2.7.0 (and I think it has), can the relevant documentation be updated?
[[http://docs.puppetlabs.com/references/2.7.0/type.html#package]]
Updated by Nick Fagerlund 6 months ago
John, what kind of change would you like to see made to the docs? I don’t think we mention the possibility or impossibility of downgrading anywhere at the moment (nor do I know which other providers allow it).
Updated by Oliver Hookins 6 months ago
Perhaps that indicates that the package providers need a new feature :downgradeable ? At least yum, apt, gem support it (and probably a few more).
Updated by John DeStefano 6 months ago
Oliver Hookins wrote:
Perhaps that indicates that the package providers need a new feature :downgradeable ? At least yum, apt, gem support it (and probably a few more).
Exactly: sorry if I wasn’t clear. From Grzegorz’s original ticket: Running “yum downgrade foo-2.5.6-38.g01d82ad” properly downgrades the package, but puppet always calls “yum install”.
Yum certainly provides this functionality, and if I’m to trust the release notes (we can’t use 2.7 yet: currently still on 2/6/x), Puppet does now as well. But according to the current docs, ‘downgradeable’ is still not a feature available for the ‘package’ type.
Updated by Nick Fagerlund 5 months ago
After considering this further, I’ve decided this doesn’t entail a documentation update.
The fact that the yum provider couldn’t downgrade was a bug, not a missing feature — we expect that any provider that lets you specify a version (“:versionable”) should let you specify any available version.
So we were already saying it could do it, and it was just broken; the behavior has now caught up with the documentation.