Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. crt.sh | example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.
Saving debug log to /some_path/log/letsencrypt.log
Requesting a certificate for glyphing.com and 17 more domains
An unexpected error occurred:
PermissionError: [Errno 1] Operation not permitted: '../../archive/my-certificates-0012/cert1.pem' -> '/some_path/live/my-certificates-0012/cert.pem'
Note that all 17 domains have been successfully validated.
I always got some error, but the private key was written in the correct folder, then I copied it together with 3x certificates from the log. The concatenated 4 certificated where c&p on HAproxy.
Now the private key is missing (the other 3 certs are stil generated).
certbot --version : 2.6.0
All other questions are not relevant since it is a manual execution, rfc2136, on my fedora notebook.
Questions:
is it a file permission problem? why is the check done at the and (after waiting 60 seconds) instead of checking at the start? because of what seems a local problem I have lost my 5 attempts in 168 hours
if all my configurations are absolute paths, why the error message use a relative path? relative to what?
I use certbot with this settings since 2021, what breaking change has been made since April 2023?
all dirs are owned by my user and I execute certbot using my user
It's not a "check". It's one of the non-optional operations in the Certbot process that usually (read: almost always) works fine, but in your case for some reason it doesn't.
The symbolic link from /live/ to /archive/ uses relative links.
None, Certbot has always used symbolic links for this purpose.
Thank you very much. Issue solved.
I use veracrypt.
Because of the chnage in behaviour, one of the following has changed since April 2023: certbot, python, veracrypt.
But since veracrypt has had no update, the change must come from one of the other two.
Veracrypt is not a filesystem of its own: a Veracrypt "container" (if you will) needs to be formatted with a specific filesystem, e.g. FAT, Ext4 or NTFS.
Have you always used Certbot on that FAT filesystem earlier? As that shouldn't have worked in the first place.
The answer is yes, and because of that reason I say that something has changed.
The symlink must always have been an issue, but the pem file in keys folder (private key) has always been written raw.
From a logical point of view I see two possibilities:
there has been a change in how keys/my-certificates-0013.pem is written (from raw to symlink)
there has been a change in the order how files are written/symlinked, thus the error blocks now keys/my-certificates.pem to be written
But at this point, this is a pure philosophical question
Yes (I always had an error) and no (at the end I always got all my certs).
As I wrote, I copied the public keys from the log, but the private key have been written in the keys folder at least until April 2023
Certbot will no longer save previous CSRs and certificate private keys to /etc/letsencrypt/csr and /etc/letsencrypt/keys, respectively. These directories may be safely deleted.
(…) the private key was written in the correct folder (…)
You didn't mention you were using the /keys/ directory though It's quite unusual to use the /keys/ directory and the requirement to fetch the certs from the log, as everything should be available in the /archive/ directory. I don't think the PermissionError should affect that?
Edit: According to the code indeed the files are first saved to /archive/ in the function save_successor() and after that the symbolic links are updated in the function update_all_links():
Basically I had the permission error, but also my workaround that allowed me to put together the whole cert chain until the change. I never thought about the symlink.
From now on I'll be able to use the correct method and save me time. Thank you.