On Wednesday, November 20, 2013 6:22:35 AM UTC-6, Jason Antman wrote:
>
> I'll wager that Michael is correct here (based on what he says, not just 
> his knowledge of packaging). 
>
> Can you provide the actual, full names of the package in question, or 
> the rpm -qi output? 
>
> My guess, based on having the same problem, is that if 
> ensure => '5.35.0-3_el5' 
> is failing, then you'll have success with 
> ensure => '5.35.0-3_el5.x86_64' 
>
>

This does resemble a package architecture issue, but after analyzing the 
provider source, I don't think that's it.  The relevant line appears to be 
this one:

raise Puppet::Error, "Failed to update to version #{should}, got version 
#{is[:ensure]} instead" if should && should != is[:ensure]


Note in particular that that error will be raised only if 'should' is 
unequal to 'is[:ensure]', but the error message Richie reports does not 
appear to show the two differing.  My best guess as as to how to resolve 
the apparent discrepancy is that the two strings are rendered unequal by an 
encoding mismatch.  (Thanks a lot, Ruby, for per-string encodings. :-( )  
Alternatively, it might be that the 'should' string contains a non-printing 
character.

I would check the relevant manifest file for non-printing characters first, 
as that should be relatively easy to do.  I am uncertain how an encoding 
mismatch might crop up here, or how best to resolve it if it did, but my 
first attempt would be to ensure that all manifests are encoded in the text 
encoding for the locale in which the master runs (probably the system's 
default locale, but verify).


By the way, if you want to specify package arch in a resource declaration, 
then you must append the .<arch> to the resource title, not add it to the 
'ensure' value.

 

> I can't find the supporting documentation at the moment, but based on 
> how the package is built (well, the values of certain fields/parameters 
> in the spec file), there are only certain substrings of the full package 
> name (packagename-X.Y.Z-release.dist.arch) that yum recognizes. 
>
> My memory of this is that you can either specify the version (X.Y.Z) or 
> you have to specify *everything* in the package 
> name/version/release/dist/arch. Or you can specify "name.arch" and a 
> version, as Michael suggested.
>


Yum understands name and name-version-release, with or without .arch.  It 
does not understand name-version (without -release), with or without the 
arch.


John

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/10c210a4-43ec-48f3-a499-0fb1d175e9d6%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to