Webroot dir name with ## characters not renewing

Hello, i’m unable to renew certficates because the directory name contains two “##” in their name (it’s a java web app deployed on a Tomcat container) and the name of the web app directory is like ROOT##20190622 so i have in the webroot_map = /usr/local/tomcat/webapps/ROOT##20190622, if i try to renew the certificates, i got a No such file or directory: ‘/usr/local/tomcat/webapps/ROOT’
It’s not reading the ‘##’ and everything after it
Is there a way i can escape the “##” characters on the renew conf file?

My domain is: dumau.org

I ran this command:
certbot renew

It produced this output:
Saving debug log to /var/log/letsencrypt/letsencrypt.log

Processing /usr/local/etc/letsencrypt/renewal/dumau.org.conf

Cert is due for renewal, auto-renewing…
Plugins selected: Authenticator webroot, Installer None
Renewing an existing certificate
Performing the following challenges:
http-01 challenge for dumau.org
http-01 challenge for www.dumau.org
Cleaning up challenges
Encountered exception during recovery:
Traceback (most recent call last):
File “/usr/local/lib/python2.7/site-packages/certbot/error_handler.py”, line 108, in _call_registered
File “/usr/local/lib/python2.7/site-packages/certbot/auth_handler.py”, line 323, in _cleanup_challenges
File “/usr/local/lib/python2.7/site-packages/certbot/plugins/webroot.py”, line 224, in cleanup
OSError: [Errno 2] No such file or directory: ‘/usr/local/tomcat/webapps/ROOT/.well-known/acme-challenge/HoStOiR35v6OSeRScRYSmxNSSEPbtGKPiC3-cWvfXzk’
Attempting to renew cert (dumau.org) from /usr/local/etc/letsencrypt/renewal/dumau.org.conf produced an unexpected error: [Errno 2] No such file or directory: ‘/usr/local/tomcat/webapps/ROOT’. Skipping

My web server is (include version):
Apache Tomcat 8 / Nginx proxy

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

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

Hi @wilson1,

Welcome to the community forum! Can you try editing your webroot_map as follows?

webroot_map = '/usr/local/tomcat/webapps/ROOT##20190622'

If the test above fails, can you try creating a symlink without the ## to that directory?

ln -s '/usr/local/tomcat/webapps/ROOT##20190622' /usr/local/tomcat/webapps/ROOT

Failing both of those tests, I recommend filing an issue to the certbot team over at https://github.com/certbot/certbot/issues.


Hi @Phil, you saved the day, the symlink worked!
Thank you!

1 Like

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