# Problem renewal certificates

**URL:** <https://community.letsencrypt.org/t/problem-renewal-certificates/154388>\
**Category:** Help\
**Created:** [June 23, 2021, 6:41am UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388 "2021-06-23T06:41:54Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cyb0rg42](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/cyb0rg42/32/50605_2.png) [@Cyb0rg42](https://community.letsencrypt.org/u/Cyb0rg42)\
**Post date:** [June 23, 2021, 6:41am UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/1 "2021-06-23T06:41:54Z")

</div>

Hi,

I'm using Ubuntu 20.04.02 LTS and having issues with certbot. For a few weeks, I cannot renew my certificates.

CLI: certbot certonly --manual --preferred-challenges dns -d \*.soc-bd.nl -d soc-bd.nl

I get the following error log:  
aving debug log to /var/log/letsencrypt/letsencrypt.log  
Plugins selected: Authenticator manual, Installer None  
An unexpected error occurred:  
Traceback (most recent call last):  
File "/usr/lib/python3/dist-packages/requests/models.py", line 379, in prepare\_url  
scheme, auth, host, port, path, query, fragment = parse\_url(url)  
File "/usr/lib/python3/dist-packages/urllib3/util/url.py", line 392, in parse\_url  
return six.raise\_from(LocationParseError(source\_url), None)  
File "", line 3, in raise\_from  
urllib3.exceptions.LocationParseError: Failed to parse: [https://acme-v02.api.letsencrypt.org/directory](https://acme-v02.api.letsencrypt.org/directory)

During handling of the above exception, another exception occurred:

requests.exceptions.InvalidURL: Failed to parse: [https://acme-v02.api.letsencrypt.org/directory](https://acme-v02.api.letsencrypt.org/directory)  
Please see the logfiles in /var/log/letsencrypt for more details.

Any idea what could be wrong? I have reinstalled urllib3 and certbot. Doesn't clear the issue.

Regards,  
Karl

---

<div class="post-metadata">

**Author:** ![\_az](https://avatars.discourse-cdn.com/v4/letter/_/22d042/32.png) [@\_az](https://community.letsencrypt.org/u/_az)\
**Post date:** [June 23, 2021, 7:53am UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/2 "2021-06-23T07:53:25Z")

</div>

From searching around, it looks like it might be a problem with the `python3-six` package.

Perhaps try:

```
sudo apt install --reinstall python3-six
```

---

<div class="post-metadata">

**Author:** ![Cyb0rg42](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/cyb0rg42/32/50605_2.png) [@Cyb0rg42](https://community.letsencrypt.org/u/Cyb0rg42)\
**Post date:** [June 23, 2021, 8:21am UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/3 "2021-06-23T08:21:03Z")

</div>

Did the reinstall. Didn't fix the issue.  
wget [https://acme-v02.api.letsencrypt.org/directory](https://acme-v02.api.letsencrypt.org/directory) is working fine. So the site is reachable.

---

<div class="post-metadata">

**Author:** ![Osiris](https://avatars.discourse-cdn.com/v4/letter/o/839c29/32.png) [@Osiris](https://community.letsencrypt.org/u/Osiris)\
**Post date:** [June 23, 2021, 4:51pm UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/4 "2021-06-23T16:51:54Z")

</div>

Well, if I read the code for [`parse_url()`](https://github.com/urllib3/urllib3/blob/73c7e0356d90e5a4618f11faeb86b0b36d24e9d8/src/urllib3/util/url.py#L337-L439) correctly, the exception is raised on any `ValueError` or `AttributeError` in the `try:` block, which contains 24 lines of code.

However, without being able to reproduce the error, it's rather hard to debug it locally I'm afraid.

---

<div class="post-metadata">

**Author:** ![Cyb0rg42](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/cyb0rg42/32/50605_2.png) [@Cyb0rg42](https://community.letsencrypt.org/u/Cyb0rg42)\
**Post date:** [June 24, 2021, 1:14pm UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/5 "2021-06-24T13:14:05Z")

</div>

Fixed the problem. I have install certbot via apt install certbot. This version was causing the problem. The snap install version is ok. I will open a cause with Ubuntu.

Thanks for your support.

---

<div class="post-metadata">

**Author:** ![Osiris](https://avatars.discourse-cdn.com/v4/letter/o/839c29/32.png) [@Osiris](https://community.letsencrypt.org/u/Osiris)\
**Post date:** [June 24, 2021, 4:49pm UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/6 "2021-06-24T16:49:46Z")

</div>

I think the snap version of certbot comes with the Python dependencies embedded in the snap, so that would indeed fix this issue, but just for certbot. Other packages/applications might suffer from the same bug.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/letsencrypt/original/3X/c/a/ca6c06ea1ea201324bba7048c6841ce60236468d.png) [@system](https://community.letsencrypt.org/u/system)\
**Post date:** [July 24, 2021, 4:49pm UTC](https://community.letsencrypt.org/t/problem-renewal-certificates/154388/7 "2021-07-24T16:49:53Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
