Certbot or letsencrypt command error

letsencrypt
v7

(Pasquale Inglese) #1

NethServer Version: NethServer release 7.4.1708 (Final)
Module: LetsEncrypt

Hi All,
I have found a problem with certbot or letsencrypt command.
When I try to renew the certificate of NS from CLI I have this error:

[root@gateway]# letsencrypt renew
Traceback (most recent call last):
  File "/usr/bin/letsencrypt", line 9, in <module>
    load_entry_point('certbot==0.22.2', 'console_scripts', 'certbot')()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 480, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2693, in load_entry_point
    return ep.load()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2324, in load
    return self.resolve()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2330, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "/usr/lib/python2.7/site-packages/certbot/main.py", line 20, in <module>
    from certbot import client
  File "/usr/lib/python2.7/site-packages/certbot/client.py", line 13, in <module>
    from acme import client as acme_client
  File "/usr/lib/python2.7/site-packages/acme/client.py", line 36, in <module>
    urllib3.contrib.pyopenssl.inject_into_urllib3()
  File "/usr/lib/python2.7/site-packages/urllib3/contrib/pyopenssl.py", line 112, in inject_into_urllib3
    _validate_dependencies_met()
  File "/usr/lib/python2.7/site-packages/urllib3/contrib/pyopenssl.py", line 147, in _validate_dependencies_met
    raise ImportError("'pyOpenSSL' module missing required functionality. "
ImportError: 'pyOpenSSL' module missing required functionality. Try upgrading to v0.14 or newer.

Currently, the version of pyOpenSSL.x86_64 installed in NS is 0.13.1-3.el7 and I have tried to upgrade to version 0.14 but no package is present from centos streaming for the update.

Does anyone have suggestions for possible solutions?
Thanks!


(Markus Neuberger) #2

Hi Pasquale,

did you update your system?

I have pyOpenSSL 0.13.1-3 too and it’s working so I recommend a reinstall of pyopenssl first:

yum reinstall pyOpenSSL

If reinstalling did not work you may try the following:

pip uninstall requests
yum reinstall python-requests

pip uninstall six
yum reinstall python-six

pip uninstall urllib3
yum reinstall python-urllib3

Sources:


(Pasquale Inglese) #3

Thanks, Markus
your indications have been useful to solve the problem