0

Installing python3-setuptools-39.2.0-10.el7.noarch.rpm file by sudo rpm -i command on Red Hat 7.6 without internet access produced an error with messages

/usr/bin/python3 is needed by python3-setuptools~~
python(abi) = 3.6 is needed by python3-setuptools~~

The RHEL7.6 system came with Python 2.7 and I installed Python 3.9.2 from the official Python.org source tgz file.

In the /usr/bin directory, there are files named python, python2, and python2.7 but not python3.

I don't understand why it requires python '3.6'

1
  • I also wonder what 'abi' stand for
    – user67275
    Mar 30, 2021 at 0:10

1 Answer 1

2

I also wonder what 'abi' stand for

I don't understand why it requires python '3.6'

ABI stands for Application binary interface and it is the reason why you can't install python3-setuptools package -- it was build with Python 3.6 so it can't be run with newer Python*. If you install Python 3.9 manually, you can't use system packages build with Python 3.6, you must install other Python modules manually too or install Python 3.6 from repositories, you can for example setup an offline local mirror with your subscription (this howto is for RHV, but similar approach will work for RHEL too, you can also check this customer portal article that explains how to create local repo using reposync).

*) Python is an interpreted language so ABI usually doesn't play a big role when working with it, but Python itself is written in C so modules that are also written in C (use the Python internal library) are compiled against specific version, Python does not guarantee ABI stability between minor releases.

2
  • Note that the “offline local mirror” instructions you linked to are part of RHV, not RHEL; that’s a different subscription. The basics are similar, but users following the instructions there exactly are liable to run into errors. RHEL 7 has a python3 package in the base repositories (used by the system packages, in version 3.6); Python 3.8 is available in Software Collections. Mar 30, 2021 at 7:30
  • Thanks for correcting me, I really should have read more than the first half of the article name :-) I've updated my answer and added link to a customer portal solution which is for RHEL (but requires RH account). Mar 30, 2021 at 8:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .