Description of problem: On a system with Python2.7 and Python2.6, with Python2.7 being the default, site-packages from GlusterFS and Python dependency prettytable are installed into Python2.6 when install via rpm packages. When running gluster commands that depend on those they are not found. Version-Release number of selected component (if applicable): GlusterFS 3.12 Example: $ sudo gluster-mountbroker setup /var/mountbroker-root geogroup this command comes back with an error: Traceback (most recent call last): File "/usr/sbin/gluster-mountbroker", line 5, in <module> from gluster.cliutils import (execute, Cmd, node_output_ok, ImportError: No module named gluster.cliutils Fix without changing Python default to 2.6: $ sudo cp -r /usr/lib/python2.6/site-packages/* /usr/lib/python2.7/site-packages/ $ sudo yum install python27-prettytable Because the gluster documentation states support for Python2.6 'or higher', wouldn't a better approach of the install be to install packages/dependencies into all Python2.6 or higher versions on the system at the time of install? I wonder actually what happens on a system with only Python2.7 at the time of install.
Moving this issue to upstream
Where is it upstream?
(In reply to Yaniv Kaul from comment #3) > Where is it upstream? Product and version of bug is changed to upstream > Product: Red Hat Gluster Storage → GlusterFS > Version: unspecified → mainline site-lib directory to install python library is fetched using below command in glusterfs spec file(https://github.com/gluster/glusterfs/blob/master/glusterfs.spec.in#L165). ``` %{!?python2_sitelib: %global python2_sitelib %(python2 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} ``` If rpms are built with Python 2.6(May be default in build machine) then after gluster rpms install it will install to the same directory even though User installed the newer version of Python.
Luckily I believe we've all moved to Python 2.7? Is that something we still need to handle (ignoring Python 2 / Python 3 for this discussion)
(In reply to Yaniv Kaul from comment #5) > Luckily I believe we've all moved to Python 2.7? Is that something we still > need to handle (ignoring Python 2 / Python 3 for this discussion) Yes, Python 2.7 is available in CentOS 7.