How to get rid of "Server Certificate Verification Failed"?

So I was trying to add SSL to my site using this link

But I messed up a few things as my SSL was successful but my site was showing an Nginx page rather than my site so I deleted and removed Nginx and Certbot. Now I am unable to install Nginx again due to “Server certificate verification failed”. Can someone one of you help me to resolve this issue?

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Site Moderator
Site Moderator badge
August 5, 2022

Hi @littleturquoisesquid,

That’s quite weird. When you try and run:

  1. yum install nginx


  1. apt install nginx

You see the above error “Server certificate verification failed”, is that correct?

Additionally, what I’ll recommend is to only rework the nginx .conf of your app located in /etc/nginx/sites-enabled/nameof.conf

As for Certbot, if you’ve selected the option to do the redirect for you, you’ll be able to see a file called /etc/nginx/sites-enabled/nameof-ssl.conf. You can remove that one as well, you’ll be able to recreate it from Certbot afterwards.

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up