Cerbot ssl fail on openlitespeed server

Certbot can obtain and install HTTPS/TLS/SSL certificates. By default,
it will attempt to use a webserver both for obtaining and installing the
certificate.
certbot: error: argument --webroot-path/-w: expected one argument
root@srv494115:~# sudo certbot certonly --webroot -w /usr/local/lsws/App/html/ -d app.appnetsoo.com
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Requesting a certificate for app.appnetsoo.com

Certbot failed to authenticate some domains (authenticator: webroot). The Certificate Authority reported these problems:
Domain: app.appnetsoo.com
Type: unauthorized
Detail: 91.108.120.67: Invalid response from http://app.appnetsoo.com/.well-known/acme-challenge/VJPx1u3SWWgNM9yMFkRO2xosMQHZbbhZ20RbHBL4ROk: 404

Hint: The Certificate Authority failed to download the temporary challenge files created by Certbot. Ensure that the listed domains serve their content from the provided --webroot-path/-w and that files created there can be downloaded from the internet.

Welcome @oshandata

First, I moved your post to the Help category. Had you posted there you would have been asked to answer some questions for us to help. You provided most of that info anyway but some more info would be helpful. Please answer the questions from that form that I show below.

I am puzzled about the "argument" error. You show it before your Certbot command. Was it displayed after that Certbot command? Because the format of your command looks correct.

Although, the folder used for the -w option probably does not match the vhRoot folder in your LiteSpeed config for this domain and URI. The "404" in the error means your server replied with this "404 Not Found". Certbot places the challenge token in the -w folder so your server must be able to find it there when the Let's Encrypt server asks for it.

Please answer these as best you can

My web server is (include version):

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

My hosting provider, if applicable, is:

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

Show output of certbot --version

Describe briefly how you installed Certbot (apt, snap, pip ...)

1 Like

I'm pretty sure you can ignore that first bit.

1 Like

I am pretty sure too :slight_smile: But, they thought it important enough to post it so wanted to be sure I understood what they meant

I know the current version of Certbot fails when that error is issued. But, I wasn't sure all prior versions did. If an older version just ignored the faulty -w the default webroot folder would cause a 404 as it would not match the LiteSpeed default. Admittedly, this is highly unlikely to be the cause of their 404. Much more likely related to my other explanation.

2 Likes

litespeed : 1.7.19

OS : ubuntuhosting provider : hostinger
certbot version : 1.21.0

Let us start at the beginning. Because I see you got a cert on July 7 so you should be using that.

What does this show

sudo certbot certificates
2 Likes

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