Certbot --apache not working : /

Hello the community !

I got actually problems when I run the command certbot --apache
The console say me this :

The apache plugin is not working; there may be problems with your existing configuration.
The error was: PluginError(‘There has been an error in parsing the file /etc/apache2/sites-available/jarl-le-ssl.conf.save on line 1: Syntax error’,)

I m a big noob in linux if anyone can suggest me some solutions thank you !

And where can I found a tutorial for unsinstall completly and properly certbot and let’s encrypt ?

Thanks !

Hi @corke,

Can you post the contents of that file here?

Hi Schoen,

Thank for reply, there is the code :

<IfModule mod_ssl.c>

<VirtualHost *:443>
ServerAdmin contact.jarl.fr@gmail.com
ServerName www.jarl.fr
ServerAlias jarl.fr

DocumentRoot /var/www/jarl-home
<Directory />
	Options FollowSymLinks
	AllowOverride All
<Directory /var/www/jarl-home>
	Options Indexes FollowSymLinks MultiViews
	AllowOverride All
	Order allow,deny
	allow from all

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
	AllowOverride None
	Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
	Order allow,deny
	Allow from all

ErrorLog /var/log/apache2/error.log

# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn

CustomLog /var/log/apache2/access.log combined

Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
    Options Indexes MultiViews FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
    Allow from ::1/128

SSLCertificateFile /etc/letsencrypt/live/www.jarl.fr-0002/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/www.jarl.fr-0002/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf

I guess the .save is a backup that came from some other program editing this file… do you remember having edited it for any reason?

There’s no </IfModule> at the end?

Could you move it out of sites-available temporarily, maybe into your home directory?

All have started when I would like change the directory of one my site. so yes I have doing editit on it, I remember I have try delete them but after the apache2 would not restart, so I have recreate an empty file and it’s rework for apache

I think the best solution should be : unsintall let’s encrypt / certbot completly then do a proper install. but If we can solve it it’s good too ^^

Sorry I have copy wrong (Have problem for copy) : I have upload here : https://jarl.fr/certbothelp.txt

really thanks for your help

I don’t think that uninstalling and reinstalling Certbot will help. If you uninstall a Certbot package, that does not any Apache configuration files that Certbot has created (or that were created for any other reason).

So, when you reinstall Certbot, this particular file will still exist and will probably still generate the same error.

Could you try moving that file into your home directory?

Hi, I m so sorry I have copy the wrong file ! I show you jarl-le-ssl.conf and not jarl-le-ssl.conf.save

I have uptaded you should see the good one now sorry ^^

After delete the file it’s work did it’s good ? or should I keep it ?

Hi @corke,

I looked at the corrected file that you uploaded. The reason for the problem is the very first line of that file

<Ihttps://jarl.fr/fModule mod_ssl.c>

where you’ve pasted the URL of your site into what should say

<IfModule mod_ssl.c>

This probably happened while you were editing the file in a text editor.

I think you can delete the .save file, because it’s simply meant to be a backup copy of another file that you already have and are using. But as long as it’s not inside of sites-available, it shouldn’t be able to harm anything!

1 Like

Ok nice that work :slight_smile:
thank you !

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