Ubuntu 16.04 - Nginx - Error Type: unauthorized / Detail: Invalid response

I try to use cerbot to get cert for my web site.

I follow the tutorial here : https://certbot.eff.org/#ubuntuxenial-nginx

But after trying to : sudo letsencrypt certonly --webroot -w /var/www/gfelot -d www.gfelot.xyz -d gfelot.xyz

I got :

IMPORTANT NOTES:
 - The following errors were reported by the server:

   Domain: www.gfelot.xyz
   Type:   unauthorized
   Detail: Invalid response from
   http://www.gfelot.xyz/.well-known/acme-challenge/ZQn1h3R91nR7Oe-Z3fzfEMIRdkeite2cs8x4m894AEA:
   "<html>
   <head><title>404 Not Found</title></head>
   <body bgcolor="white">
   <center><h1>404 Not Found</h1></center>
   <hr><center>"

   Domain: gfelot.xyz
   Type:   unauthorized
   Detail: Invalid response from
   http://gfelot.xyz/.well-known/acme-challenge/lIwDPTqC8WpqV-dekQFykj9zlrFUlbE762PgGmPTqZA:
   "<html>
   <head><title>404 Not Found</title></head>
   <body bgcolor="white">
   <center><h1>404 Not Found</h1></center>
   <hr><center>"

   To fix these errors, please make sure that your domain name was
   entered correctly and the DNS A record(s) for that domain
   contain(s) the right IP address. 

I looked around on StackOverflow and other forum like this one I cannot find out why this is happen.

Any idea ?

Is the web root you specify correct ?

does the folder /var/www/gfelot exist ? or is it /var/www/gfelot.zyz ?

if you place a file at /var/www/gfelot/.well-known/acme-challenge/test can you reach it at gfelot.xyz/.well-known/acme-challenge/test ?

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