Hi,
I copied my privacy.pem and full chain.pem keys from docker for safe copy because it was generated in a docker container. When I try to use them I get this err cannot load certificate key "/etc/letsencrypt/live/tcwlmd.com/privkey.pem": PEM_read_bio_PrivateKey() failed (SSL: error:0909006C:PEM routines:get_name:no start line:Expecting: ANY PRIVATE KEY)
Yeah at this point I need to create a new one anyways. I was desperate
I didn't know I could use openssl rsa -noout -check -in /etc/letsencrypt/live/yourdomain.tld/privkey.pem
Agreed. @molayodecker, you need to provide the complete command used so that we can try to replicate the problem and/or troubleshoot /research it further.
The only "solution" I can find online, thus far, is weird but so is this problem.
It says to make sure the file ends with "\n" [a "newline"].
So I would edit the .pem type file and simply append an "enter" at the very end; so that it adds the new blank line and then just exit saving the .pem type file.
If the file is not of .pem type then this modification should not be attempted.
From the "--- begin" and "--- end" seen above I suspect you are dealing with a .pem type file.
But you never know who might read this down the road