My domain is: vps300.arconsult.hu
I ran this command: certbot renew --dry-run
My web server is (include version): Apache 2.4.25
The operating system my web server runs on is (include version): Debian 9.13
I am running my https site on port on port 9005, not 443.
Neither port 80 nor port 443 are open.
Dryrun completes fine without error.
Newbie Question: do I need to open port 443 and/or 80 for renewal?
Thanks for reply
Peter
If you want to use http validation, port 80 is required. If you have a redirect http -> https and if you use webroot, port 443 too. So there is no general answer possible.
Thanks for reply.
According to the link you have given I was looking for the '.well-known' folder.
First I was searching on the server where the DNS A record of 'vps300.arconsult.hu' - is pointing to. and I did not find it.
Secondly I was searching for it on the main webserver where the A record arconsult.hu is pointing to - and I found it there.
This means to me that for renewal not the 'vps300.arconsult.hu' but the 'arconsult.hu' is contacted (despite the fact that the certificate contains the name 'vps300.arconsult.hu' and not 'arconsult.hu').
So the port 80 should be open on the arconsult.hu and not the vps300.arconsult.hu. Am I right?
certbot --apache
And it worked.
And I found a /public_html/.well-known/acme-challenge/ empty directory on the main domain's webpage with today's date - that's why I thought so.
But to tell the trues I don't remember the questions and answers I have given while doing 'cerbot --apache, may be there I could select validation type, I don't remember. May be I should repeat the whole process and it will turn out.
I have redone the whole installation.
Nowhere was asked which kind of validation to do.
No http://vps300.arconsult.hu/.well-known/acme-challenge/random-filename file!
The site works!
Here is the certbot --apache command output:
You have an existing certificate that has exactly the same domains or certificate name you requested and isn't close to expiry.
(ref: /etc/letsencrypt/renewal/vps300.arconsult.hu.conf)
What would you like to do?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: Attempt to reinstall this existing certificate
2: Renew & replace the cert (limit ~5 per 7 days)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): 1
Keeping the existing certificate
Created an SSL vhost at /etc/apache2/sites-available/000-default-le-ssl.conf
Enabled Apache ssl module
Deploying Certificate to VirtualHost /etc/apache2/sites-available/000-default-le-ssl.conf
Enabling available site: /etc/apache2/sites-available/000-default-le-ssl.conf
Please choose whether or not to redirect HTTP traffic to HTTPS, removing HTTP access.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: No redirect - Make no further changes to the webserver configuration.
2: Redirect - Make all requests redirect to secure HTTPS access. Choose this for
new sites, or if you're confident your site works on HTTPS. You can undo this
change by editing your web server's configuration.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): 1
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Congratulations! You have successfully enabled https://vps300.arconsult.hu
You should test your configuration at:
https://www.ssllabs.com/ssltest/analyze.html?d=vps300.arconsult.hu
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IMPORTANT NOTES:
- Congratulations! Your certificate and chain have been saved at:
/etc/letsencrypt/live/vps300.arconsult.hu/fullchain.pem
Your key file has been saved at:
/etc/letsencrypt/live/vps300.arconsult.hu/privkey.pem
Your cert will expire on 2021-05-15. To obtain a new or tweaked
version of this certificate in the future, simply run certbot again
with the "certonly" option. To non-interactively renew *all* of
your certificates, run "certbot renew"
- If you like Certbot, please consider supporting our work by:
Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate
Donating to EFF: https://eff.org/donate-le
ps.- When port 80 is closed but needed, why does dryrun runs successfully without error? One would think that dryrun mirrors the real renewing situation.
Note, possibly not related to this thread, but might be: depending on the version of certbot, it could be cached valid authorizations. I believe it's since a specific version, certbot invalidates cached authz in staging with --dry-run. In versions prior to that, --dry-run can perfectly work fine without a working situation. And as OP is running Debian....
That doesn't say much. If you're using Debians repository, it can be quite ancient. Is there a particular reason why you've removed those last questions from the questionnaire?