Webmin Let’s Encrypt Throws “Failed to Establish a New Connection”


requests.exceptions.ConnectionError: HTTPSConnectionPool(host=’’, port=443): Max retries exceeded with url: /directory (Caused by NewConnectionError(‘<urllib3.connection.VerifiedHTTPSConnection object at 0x7f94951b7860>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution’,))

Root Cause

When Webmin tries to send request to Let’s Encrypt, Let’s Encrypt is trying to get the response from the Website index page. If Let’s Encrypt cannot get the valid response (HTTP code 200), it throws an error. Following are the root causes for not getting HTTP code 200

  • DNS is not propagated
  • You created virtual server in Virtualmin but it does not have index.html or equivalent index file


If DNS is not propagated, wait for it till Let’s Encrypt is able to connect to your website.

If DNS is propagated, make sure you have index.html or equivalent index file available and accessible to outside world.

One you fix the underlying issue, you will be able to generate SSL.