scylla install on OEL: fail to install depended python-urllib3

Created on 28 Sep 2017  路  12Comments  路  Source: scylladb/scylla

Installation details
Scylla version (or git commit hash): 2.0.rc5-0.20170927.43d785a.el7.centos
Cluster size: 1
OS (RHEL/CentOS/Ubuntu/AWS AMI): OEL7.4

Description
Try to install scylla by our unstable repo, the scylla packages were actually installed, but one depended package (python-urllib3) didn't successfully installed. Sure, it's used by scylla code.

It should not a scylla issue, but we need to solve it.

Full log: urllib3.err.txt

07:58:34,086 process | Running '/bin/yum -y install scylla'
...
07:58:54,504 process | [stdout]   Installing : python-six-1.9.0-2.el7.noarch                              17/33 
07:58:54,504 process | [stdout]   Installing : python-urllib3-1.10.2-3.el7.noarch                         18/33 
07:58:54,504 process | [stdout] error: unpacking of archive failed on file /usr/lib/python2.7/site-packages/urllib3/packages/ssl_match_hostname: cpio: rename
07:58:54,505 process | [stderr] Error unpacking rpm package python-urllib3-1.10.2-3.el7.noarch
07:58:54,553 process | [stdout]   Installing : python-requests-2.6.0-1.el7_1.noarch                       19/33 
07:58:54,553 process | [stdout] error: python-urllib3-1.10.2-3.el7.noarch: install failed
...
07:58:58,057 process | [stdout] Failed:
07:58:58,057 process | [stdout]   python-urllib3.noarch 0:1.10.2-3.el7                                          
07:58:58,057 process | [stdout]
07:58:58,057 process | [stdout] Complete!
[root@localhost ~]# echo $?
1

@amnonh @syuu1228

Most helpful comment

The problem is similar with https://github.com/requests/requests/issues/2430
In my test, the python-urllib3 is conflict with the package is already installed via pip.

[root@localhost ~]# pip list|grep urllib3
urllib3 (1.22)
[root@localhost ~]# sudo pip uninstall urllib3
....
Proceed (y/n)? y
  Successfully uninstalled urllib3-1.22

Then I can successfully install `python-urllib3` package by yum.

Latest job scylla-2.0-oel7.4-rpm-test/7 is good.

All 12 comments

  1. Jenkins job log: link

  2. I can still reproduce this issue with clean vm.

[root@localhost ~]# yum install python-urllib3
...
Running transaction  
  Installing : python-six-1.9.0-2.el7.noarch                                                                               1/2
  Installing : python-urllib3-1.10.2-3.el7.noarch                                                                          2/2
Error unpacking rpm package python-urllib3-1.10.2-3.el7.noarch
error: unpacking of archive failed on file /usr/lib/python2.7/site-packages/urllib3/packages/ssl_match_hostname: cpio: rename
  Verifying  : python-six-1.9.0-2.el7.noarch                                                                               1/2
  Verifying  : python-urllib3-1.10.2-3.el7.noarch                                                                          2/2

Dependency Installed:
  python-six.noarch 0:1.9.0-2.el7

Failed:
  python-urllib3.noarch 0:1.10.2-3.el7

Complete!

[root@localhost ~]# echo $?
1

The problem is similar with https://github.com/requests/requests/issues/2430
In my test, the python-urllib3 is conflict with the package is already installed via pip.

[root@localhost ~]# pip list|grep urllib3
urllib3 (1.22)
[root@localhost ~]# sudo pip uninstall urllib3
....
Proceed (y/n)? y
  Successfully uninstalled urllib3-1.22

Then I can successfully install `python-urllib3` package by yum.

Latest job scylla-2.0-oel7.4-rpm-test/7 is good.

@amnonh So we will just leave the problem to user? it's truly not a scylla-housekeeping issue.

If so let's close this issue

@slivne

@amoskong Isn鈥檛 it only happens if user manually installed urllib3 using pip, not with yum, no?
Or, our script tries to use pip?

@syuu1228 In my test env (OEL), the urllib3 was installed by default (at least it's not installed by me manually). I can uninstall it by pip, I guess it's installed by pip, right?

@amoskong / @syuu1228 any update

No update in my side. @syuu1228 do you need more test or info from me?

This seems to be some sort of cpio unpack error due to the package including a symbolic link to a directory and/or how cpio handles directory symlinks. The workaround below seems to accomplish the packagers intention.

rpm -ivv --excludepath=/usr/lib/python2.7/site-packages/urllib3/packages/ssl_match_hostname python-urllib3-1.10.2-5.el7.noarch.rpm

then
cd /usr/lib/python2.7/site-packages/urllib3/packages/
ln -s ../../backports/ssl_match_hostname

An alternate package might switch to creating the ssl_match_hostname directory and linking to the files directly since cpio / rpm seems to work past that without issue.

Detail: CentOS7 in LXD on Ubuntu-18.04 w/ xfs on sparse lv for guest filesystem.

I still guessing this is not our packaging problem since it鈥檚 not conflicted with scylla* package, but I try to reproduce it now.

I just tried to reproduce the problem on OEL that running on AWS EC2 (ami-0c9c8d77, able to find on AWS marketplace), I didn't see any error, install finished just finely.
Here is log: https://gist.github.com/syuu1228/3f70ad82c562631c1518b1babaffd866

I still thinking it's environment dependent problem, not all OEL has the issue.
And in fact scylla-2.0-oel7.4-rpm-test is succeed now.

I can't reproduce it now either. Very strange behavior. Sorry I was no help.

Since it doesn't reproduce for two people, closing. Please re-open if the problem still happens.

Was this page helpful?
0 / 5 - 0 ratings