Failed to renew certificate with error: type object 'ClientV2' has no attribute 'get_directory'

My domain is:

I ran this command: certbot renew
It produced this output: Failed to renew certificate with error: type object 'ClientV2' has no attribute 'get_directory'

My web server is (include version): apache 2.4.54-5

The operating system my web server runs on is (include version): Debian testing

My hosting provider, if applicable, is: NA

I can login to a root shell on my machine (yes or no, or I don't know): yes

I'm using a control panel to manage my site (no, or provide the name and version of the control panel): None

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot): 2.1.0

2022-12-29 11:41:25,625:DEBUG:certbot._internal.renewal:Traceback was:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/certbot/_internal/", line 524, in handle_renewal_request
main.renew_cert(lineage_config, plugins, renewal_candidate)
File "/usr/lib/python3/dist-packages/certbot/_internal/", line 1538, in renew_cert
le_client = _init_le_client(config, auth, installer)
File "/usr/lib/python3/dist-packages/certbot/_internal/", line 832, in _init_le_client
return client.Client(config, acc, authenticator, installer, acme=acme)
File "/usr/lib/python3/dist-packages/certbot/_internal/", line 297, in init
acme = acme_from_config_key(config, self.account.key, self.account.regr)
File "/usr/lib/python3/dist-packages/certbot/_internal/", line 72, in acme_from_config_key
directory = acme_client.ClientV2.get_directory(config.server, net)
AttributeError: type object 'ClientV2' has no attribute 'get_directory'

Hi @GieltjE-FYN, and welcome to the LE community forum :slight_smile:

How did you install certbot?

Also, there seems to be an unrelated problem with IPv6 access to your site:

curl -Ii6
curl: (56) Recv failure: Connection reset by peer

apt-get install curl, has been functioning fine for the past few years.

The ipv6 issue is strange, when I perform it from a different data center it is fine:

curl -Ii6
HTTP/2 200
expires: Thu, 19 Nov 1981 08:52:00 GMT
cache-control: no-store, no-cache, must-revalidate
pragma: no-cache
link:; rel="",; rel="alternate"; type="application/json",; rel=shortlink
x-content-type-options: nosniff
x-xss-protection: 1; mode=block
x-frame-options: SAMEORIGIN
expect-ct: max-age=300, report-uri=""
strict-transport-security: max-age=31536000; includeSubDomains; preload
set-cookie: campingdekluis=k59v34t0341vp84rpqpot3c1ns; path=/;HttpOnly;HttpOnly;Secure
referrer-policy: strict-origin-when-cross-origin
content-type: text/html; charset=UTF-8
date: Thu, 29 Dec 2022 11:13:02 GMT
server: Apache

apt-get install certbot ???

That may be at this end...


apt-get install certbot indeed, my bad, being a bit overrun with work.

1 Like

Try these instructions instead:
Certbot Instructions | Certbot (


ClientV2.get_directory was added in certbot 2.0.0 and acme 2.0.0. There seems to be a version conflict between the two packages: somehow your Certbot is version 2.0.0 or newer, but your acme package is older than 2.0.0.


Sorry, it was a problem at my end.
It now looks fine:

curl -Ii6
HTTP/1.1 301 Moved Permanently
Date: Thu, 29 Dec 2022 12:48:35 GMT
Server: Apache
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
X-Frame-Options: SAMEORIGIN
Content-Type: text/html; charset=iso-8859-1

pip3 somehow had acme installed, removed it, reinstalled the debian one and all is fine now.

Thanks for the support :slight_smile:


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