404 error nginx

IMPORTANT NOTES:

  • The following errors were reported by the server:

    Domain: skylimservices.tk
    Type: unauthorized
    Detail: Invalid response from
    http://skylimservices.tk/.well-known/acme-challenge/UY9hJDQZ8yemP62l1L94CcNI7 ypTIhxcXz9EhrnVtN8:
    "

    404 Not Found

    404 Not Found


    "

    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.
    root@debian-s-1vcpu-1gb-blr1-spih-01:~# hxcXz9EhrnVtN8: "

404 Not Found

404 Not Found


"

-bash: hxcXz9EhrnVtN8:: command not found
root@debian-s-1vcpu-1gb-blr1-spih-01:~# ^C
root@debian-s-1vcpu-1gb-blr1-spih-01:~# 404 Not Found</hea d>
-bash: syntax error near unexpected token <' root@debian-s-1vcpu-1gb-blr1-spih-01:~# <body bgcolor="white"> -bash: syntax error near unexpected token newline'
root@debian-s-1vcpu-1gb-blr1-spih-01:~#

404 Not Found

</cente r>
-bash: syntax error near unexpected token <' root@debian-s-1vcpu-1gb-blr1-spih-01:~# <hr><center>" -bash: syntax error near unexpected token <'
root@debian-s-1vcpu-1gb-blr1-spih-01:~#
root@debian-s-1vcpu-1gb-blr1-spih-01:~# sudo certbot certonly --webroot -w /var/www -d skylimservices.tk -d
root@debian-s-1vcpu-1gb-blr1-spih-01:~# sudo certbot certonly --webroot -w /var/www -d skylimservices.tk -d www.skylimservices.tk
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for skylimservices.tk
http-01 challenge for www.skylimservices.tk
Using the webroot path /var/www for all unmatched domains.
Waiting for verification...
Cleaning up challenges
Failed authorization procedure. www.skylimservices.tk (http-01): urn:acme:error:connection :: The server could not connect to the client to verify the domain :: DNS problem: NXDOMAIN looking up A for www.skylimservices.tk, skylimservices.tk (http-01): urn:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from http://skylimservices.tk/.well-known/acme-challenge/8oQJk5qZbX0uB9XMqLvGQ9EI3MSUP_sO7IPxZyk52r8: "

404 Not Found

404 Not Found


"

IMPORTANT NOTES:

  • The following errors were reported by the server:

    Domain: skylimservices.tk

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.

  • The following errors were reported by the server:

    Domain: www.skylimservices.tk
    Type: connection
    Detail: DNS problem: NXDOMAIN looking up A for
    www.skylimservices.tk

    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. Additionally, please check that
    your computer has a publicly routable IP address and that no
    firewalls are preventing the server from communicating with the
    client. If you're using the webroot plugin, you should also verify
    that you are serving files from the webroot path you provided.

Hi,

I see that you don't have any A record point to www version of your site.
That's causing

NXDOMAIN looking up A for www.skylimservices.tk

Also, Can you check if your server /var/www has .well-known folder inside? (Since the correct ip returns 404)

Thank you

thanks for the reply. but i think i have a different need plz look into this How to get key file and cert file

can you please explain since i do not have the /.well-known folder as i hope it should be created by certbot. please let me know what i can do get that folder
thanks

What web server software do you use? What command did you run to try to obtain the certificate?

thanks for your reply.
i got the certificate and i want to keep the certificate in the phoenix server folder structure, so when a connection request comes to the phoenix server will handle the certificate part.
thank you

What command did you run to try to obtain the certificate?

this one sir…
sudo -H ./letsencrypt-auto certonly --standalone -d example.com -d www.example.com

Thanks! OK, and the nature of your problem now is that you can’t obtain a certificate, or that you’ve obtained a certificate and you don’t know how to configure your Phoenix server to use your certificate?

actually, yes.
i am still not sure about this.

Did you try following any kind of tutorial or documentation for configuring Phoenix?

For example, I just found this Stack Overflow discussion at

although it relates to a slightly different scenario, it seems to give information about the configuration. You should most likely be able to use /etc/letsencrypt/live/example.com/fullchain.pem for the certificate and /etc/letsencrypt/live/example.com/privkey.pem for the private key, replacing example.com with the name of your certificate.

Thank you very much fo the help!
thr problem was we were trying to copy the files from letsencrypt/live folder but those were links which are phoenix server was not able to understand. we took the original files from the archive folder and its working but ithe problem is i am getting the following error from my browser…
(please refer the screenshot below)

Hi

I didn’t see any issues…

Can you elaborate?

Thank you

If you do this, you should consider that you'll need to do it again every time the certificate is renewed because those files won't be updated with new versions. This must happen at least every 90 days.

Like @stevenzhu, I'm having some trouble understanding this as an error—it looks like the browser is just displaying the contents of the certificate, but not showing that something is wrong with it.

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