On Mar 19, 8:29 pm, Alan Laird <
a...@laird.net> wrote:
>
> The issue I'm chasing is that I need to install a 32bit libstdc++ to
> support a vendor supplied rpm and I already have the 64bit libstdc++
> installed.
So the vendor RPM doesn't correctly identify its requirements? That's
quite strange, as the RPM build tools are really quite good at
identifying library dependencies, including architecture. If the
RPM's requires are right and a suitable library is available in one of
the configured repositories, then yum should find it and install it
automatically when you ask it to install the main RPM. That's one of
the main selling points of yum.
In the unlikely event that the vendor RPM really is broken, then
perhaps the best course of action would be to ask the vendor to fix
it. If that isn't possible / fruitful then you could try using
rpmrebuild on the binary RPM to fix the package yourself.
If the RPM is correct, then all this other work you are trying to do
is probably pointless. Just let yum do its job.
> Before today, I was hacking my way around this issue by
> installing the 32bit libstdc++ rpm by a package statement that uses
> name.version.architecture. This is was working until one of the
> systems in my pool had a newer version of the same name and
> architecture which causes puppet to throw this error:
>
> err: /Stage[main]/Lsi6::Management/Package[libstdc++34-3.4.0-1.i386]/
> ensure: change from absent to present failed: Execution of '/usr/bin/
> yum -d 0 -e 0 -y install libstdc++34-3.4.0-1.i386' returned 1:
>
> Transaction Check Error:
> file /usr/lib/libstdc++.so.6 from install of libstdc+
> +34-3.4.0-1.i386 conflicts with file from package libstdc+
> +-4.4.6-3.el6.i686
That's a package incompatibility problem. It really oughtn't to be
the case that any machine is configured with yum repos that contain
both of those packages. Perhaps the problem is that the libstdc++34
package you are trying to install is broken, as I think GCC 3's libstdc
++ ought to be /usr/lib/libstdc++.so.5, not *.6.
Is that 32-bit package coming from your distro's repo, or from some
third-party repo? The second package name it appears you may be using
RHEL 6 or one of its clones, such as CentOS 6, but the 32-bit package
is certainly not from any of those distributions. With RHEL-family
distros, you should be looking at package "compat-libstdc++-33" for
the GCC 3 C++ lib.
> It seems like there must be an elegant way to install the latest of
> name.*.architecture where architecture is i386 or i686.
Sadly, there isn't. RPMs have a composite identifier (name, arch)
that has never meshed well with Puppet's model. That causes few
problems in practice, however, because yum does a decent job of
papering over the distinction, because it only affects multilib
systems, and because it is rare that you need to specify a particular
arch to Puppet even on multilib systems.
In your case, I think you have at least one of these deeper problems:
1) Your Puppet manifests overspecify your requirements. You shouldn't
need to specify an RPM's requirements to Puppet when you are using the
Yum provider. Let yum do its job, and you can get on with your own.
2) Your yum repository configuration is screwed up. It appears to
include repos that are not fully compatible with the distro you are
using. If you cannot altogether remove / disable the offending repos
then at least set up priorities, excludes, includepkgs, or other
options to limit the view of those repositories to the packages you
need from them.
John