AH00526: Syntax error in sites-enabled

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.

My domain is: rejuvenatedremnants.com

I ran this command: sudo certbot --apache -d rejuvenatedremnants.com -d www.rejuvenatedremnants.com

It produced this output:

Saving debug log to /var/log/letsencrypt/letsencrypt.log
Error while running apache2ctl configtest.
Action 'configtest' failed.
The Apache error log may have more information.

AH00526: Syntax error on line 33 of /etc/apache2/sites-enabled/rejuvenatedremnants.com-le-ssl.conf:
SSLCertificateFile: file '/etc/letsencrypt/live/rejuvenatedremnants.com/fullchain.pem' does not exist or is empty

The apache plugin is not working; there may be problems with your existing configuration.

The error was: MisconfigurationError("Error while running apache2ctl configtest.\nAction 'configtest' failed.\n

The Apache error log may have more information.\n\n
AH00526: Syntax error on line 33 of /etc/apache2/sites-enabled/rejuvenatedremnants.com-le-ssl.conf:\nSSLCertificateFile:

file '/etc/letsencrypt/live/rejuvenatedremnants.com/fullchain.pem' does not exist or is empty\n")

My web server is (include version):

Server version: Apache/2.4.52 (Ubuntu)
Server built: 2023-10-26T13:44:44

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

Distributor ID: Ubuntu
Description: Ubuntu 22.04.4 LTS
Release: 22.04
Codename: jammy

My hosting provider, if applicable, is:

VPS Hostinger

I can login to a root shell on my machine (yes or no, or I don't know): Yes

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

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot): certbot 2.9.0

What happened to the file /etc/letsencrypt/live/rejuvenatedremnants.com/fullchain.pem?

1 Like

I don't believe I ever had it generated, at least on this vps.

You should get that certificate using --standalone with the proper --cert-name and after Apache starts, use certbot reconfigure --cert-name $SOMETHING --apache

1 Like

The command fails with:

root@www:~# sudo certbot reconfigure --cert-name rejuvenatedremnants.com --apache
Saving debug log to /var/log/letsencrypt/letsencrypt.log
An existing certificate with name rejuvenatedremnants.com could not be found. Run certbot certificates to list available certificates.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.

You do have to run your command again, before you do that. Replace --apache with --standalone and add --cert-name

1 Like

I must not be following along correctly. Here are some of the results of three commands:

root@www:~# sudo certbot --standalone -d rejuvenatedremnants.com -d www.rejuvenatedremnants.com
Saving debug log to /var/log/letsencrypt/letsencrypt.log
With the standalone plugin, you probably want to use the "certonly" command, eg:

certbot certonly --standalone

(Alternatively, add a --installer flag. See User Guide — Certbot 2.10.0.dev0 documentation
and "--help plugins" for more information.)
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.
root@www:~# sudo certbot reconfigure --cert-name rejuvenatedremnants.com --apache
Saving debug log to /var/log/letsencrypt/letsencrypt.log
An existing certificate with name rejuvenatedremnants.com could not be found. Run certbot certificates to list available certificates.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.
root@www:~# sudo certbot --apache -d rejuvenatedremnants.com -d www.rejuvenatedremnants.com
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Error while running apache2ctl configtest.
Action 'configtest' failed.
The Apache error log may have more information.

AH00526: Syntax error on line 33 of /etc/apache2/sites-enabled/rejuvenatedremnants.com-le-ssl.conf:
SSLCertificateFile: file '/etc/letsencrypt/live/rejuvenatedremnants.com/fullchain.pem' does not exist or is empty

The apache plugin is not working; there may be problems with your existing configuration.
The error was: MisconfigurationError("Error while running apache2ctl configtest.\nAction 'configtest' failed.\nThe Apache error log may have more information.\n\nAH00526: Syntax error on line 33 of /etc/apache2/sites-enabled/rejuvenatedremnants.com-le-ssl.conf:\nSSLCertificateFile: file '/etc/letsencrypt/live/rejuvenatedremnants.com/fullchain.pem' does not exist or is empty\n")
root@www:~#

From what I am hearing, there are three commands:

  1. sudo certbot reconfigure --cert-name rejuvenatedremnants.com --apache
  2. sudo certbot --standalone -d rejuvenatedremnants.com -d www.rejuvenatedremnants.com
    ...and lastly...
  3. sudo certbot --apache -d rejuvenatedremnants.com -d www.rejuvenatedremnants.com

All three error per above. Apologies for my ineptitude. Standing by for correction. Thank you!!!

And, trying, with Apache stopped, certbot certonly --standalone:

root@www:~# certbot certonly --standalone
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Please enter the domain name(s) you would like on your certificate (comma and/or
space separated) (Enter 'c' to cancel): rejuvenatedremnants.com, www.rejuvenatedremnants.com
Requesting a certificate for rejuvenatedremnants.com and www.rejuvenatedremnants.com

Certbot failed to authenticate some domains (authenticator: standalone). The Certificate Authority reported these problems:
Domain: rejuvenatedremnants.com
Type: connection
Detail: 89.116.212.98: Fetching http://rejuvenatedremnants.com/.well-known/acme-challenge/t8pK695v57Mi2G3HX-Pt4yDt9DsD7YStOV2csV8A02o : Error getting validation data

Domain: www.rejuvenatedremnants.com
Type: connection
Detail: 89.116.212.98: Fetching http://www.rejuvenatedremnants.com/.well-known/acme-challenge/czY5EanRv1cb_a83WYOo1K-Pgff5kmI3WD4BJXQ BxBs: Error getting validation data

Hint: The Certificate Authority failed to download the challenge files from the temporary standalone webserver started by Certbot on po rt 80. Ensure that the listed domains point to this machine and that it can accept inbound connections from the internet.

Some challenges have failed.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-r un Certbot with -v for more details.

Is that the IP of your system?
Show:
curl ifconfig.me

Did you stop Apache before running that?
["certbot certonly --standalone -d rejuvenatedremnants.com -d www.rejuvenatedremnants.com"]
It looks like you did try that too...

Are there any NAT/Port Forwarding rules for incoming HTTP [TCP port 80] connections?

2 Likes

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