Unable to find a virtual host listening on port 80


Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. https://crt.sh/?q=example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.

My domain is: blackdog.straight8.com

I ran this command: certbot --apache

It produced this output:
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for blackdog.straight8.com
http-01 challenge for whitedog.straight8.com
Cleaning up challenges
Unable to find a virtual host listening on port 80 which is currently needed for Certbot to prove to the CA that you control your domain. Please add a virtual host for port 80.

My web server is (include version):
Apache, httpd-2.4.6-88.el7.centos.x86_64
web services are running on port 80 and port 443

The operating system my web server runs on is (include version):
CentOS Linux release 7.6.1810 (Core), patched up-to-date via yum

My hosting provider, if applicable, is: self-hosted

I can login to a root shell on my machine (yes or no, or I don’t know): yes

I’m using a control panel to manage my site (no, or provide the name and version of the control panel): no

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


Hi @SlimeDog

Certbot doesn’t understand your configuration.

You may have only default VirtualHosts, not explicit VirtualHosts. So add something like

<VirtualHost *:80>
    DocumentRoot "/www/example1"
    ServerName blackdog.straight8.com
    ServerAlias whitedog.straight8.com

    # Other directives here

Or add two VirtualHosts, one per domain name. Every ServerName should be used one time.


Thanks. The issue is resolved.

closed #4

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