I reloaded my server now can't install Let's Encrypt again


I keep getting this back and the lines are in red color.

:~/letsencrypt# ./letsencrypt-auto
Updating letsencrypt and virtual environment dependencies…Command “/root/.local/share/letsencrypt/bin/python2.7 -c “import setuptools, tokenize;file=’/tmp/pip-build-55zwnV/cffi/setup.py’;exec(compile(getattr(tokenize, ‘open’, open)(file).read().replace(’\r\n’, ‘\n’), file, ‘exec’))” install --record /tmp/pip-IyB_MJ-record/install-record.txt --single-version-externally-managed --compile --install-headers /root/.local/share/letsencrypt/include/site/python2.7/cffi” failed with error code 1 in /tmp/pip-build-55zwnV/cffi

I had to reinstall Ubuntu and just mostly that. I have a HDD with the www on it so keep using that. I can get on it now. But I had WordPress set for https and now I can’t go there but the main wab page works but no https just http.

Any one know how to fix this. It worked super easy on my last install that I had running for months. This is a new install. I can only guess it has some old Let’s Encrypt files on it not sure.

-Raymond Day


I fixed it.

In my /root/.local was a share folder. I renamed it to share~ and ran ./letsencrypt-auto and it worked this time!

It did make a new /root/.local/share folder.

-Raymond Day


Hello @Ray,

Remove the virtualenv, update letsencrypt client and try again.

Viewing the logs seems you have letsencrypt installed on /root/letsencrypt/ so my examples will use it:

1.- Backup and remove virtualenv

cd /root/
tar zcvf backup-local-letsencrypt.tar.gz /root/.local/share/letsencrypt/
rm -rf /root/.local/share/letsencrypt/

2.- Update letsencrypt.

If you installed letsencrypt using git clone go to the dir where it is installed and perform a git pull

cd /root/letsencrypt/
git pull

3.- Recreate the virtualenv

To recreate the virtualenv just launch letsencrypt-auto command, it will check the system depencies and will install all you need.

cd /root/letsencrypt/

If after that you get the same cffi error, check this post



I was writing my answer and didn’t see that you solved it already :wink:


Thank you sahsanu. Your “rm -rf /root/.local/share/letsencrypt/” is about what I did to fix it. But I was not sure so I renamed it. I guess I can delete that now.

Just did the SSL Server Test and it gave me a green A.

-Raymond Day