8

When installing packages via yum on a RHEL Server 6.6 system, I get the following error:

$ sudo yum install foo
Loaded plugins: product-id, rhnplugin, security, subscription-manager
This system is receiving updates from RHN Classic or RHN Satellite.
Setting up Install Process
Error: xz compression not available

Search engine searches suggest that the pyliblzma package is missing.

I can't install this via sudo yum install pyliblzma because I run into the same xz compression not available error.

Instead, I downloaded the RPM archive and installed it via rpm:

$ wget http://download.fedoraproject.org/pub/epel/6/SRPMS/pyliblzma-0.5.3-3.el6.src.rpm
$ sudo rpm -ivh pyliblzma-0.5.3-3.el6.src.rpm

It appears to not have been installed successfully; the following returns no results:

$ rpm -qa | grep pyliblzma

What should I do to correctly install pyliblzma and fix the xz compression not available error?

Alex Reynolds
  • 301
  • 1
  • 3
  • 11
  • Dodgy version of xz installed (i.e. the EPEL version and not the RHEL version) ? – steve Aug 26 '15 at 19:03
  • Have you tried `yum clean all` and then `rpmdb -v --rebuilddb`, then try running `yum install foo`? And by the way, I see you have installed source rpm, I am not sure if that's any good. – Soumyadip DM Aug 26 '15 at 19:16
  • As @SoumyadipDM mentioned, you installed a source package - src.rpm - which contains the source code and .spec file to build a binary rpm. What you should download instead is http://download.fedoraproject.org/pub/epel/6/x86_64/pyliblzma-0.5.3-3.el6.x86_64.rpm Apart from that, `yum clean all` or `rpm --rebuilddb` won't help. Would be interesting to know how you ended up with this issue ... – doktor5000 Aug 27 '15 at 20:41

3 Answers3

10

To fix this:

  1. yum remove epel-release
  2. Re-download the epel-release RPM
  3. Install it
  4. yum install pyliblzma
Alex Reynolds
  • 301
  • 1
  • 3
  • 11
3

Worked for me on CentOS 6.X

sudo rpm -e epel-release-7-5.noarch

wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm

sudo rpm -ivh epel-release-6-8.noarch.rpm

sudo yum clean all

sudo rpmdb -v --rebuilddb

sudo yum -y install libselinux-python
maulinglawns
  • 8,426
  • 2
  • 28
  • 36
HngryTgr
  • 31
  • 1
0

This worked for me:

yum remove epel-release
# Re-download the epel-release RPM
# Install it
yum install pyliblzma
jasonwryan
  • 71,734
  • 34
  • 193
  • 226
Kappy P
  • 11
  • 2