# apache2 "NameVirtualHost *:80 has no VirtualHosts" startup

## Bob Paddock

For each virtual host I create I am receiving the following

warnings in startuperror.log.  If I have two virtual hosts

I get two warnings, one for the default vhost, one for

each additional vhost.  The vhosts *do* work, but I want

these warnings to go away.

 *Quote:*   

> 
> 
> [Sat Mar 11 08:48:36 2006] [warn] NameVirtualHost *:80 has no VirtualHosts
> 
> Syntax OK
> ...

 

Here is 01_vhost.conf from /etc/apache2/vhost.d/ :

 *Quote:*   

> 
> 
> NameVirtualHost *:80
> 
> <VirtualHost *:80>
> ...

 

00_default_vhost.conf:

 *Quote:*   

> 
> 
> ### Section 3: Virtual Hosts
> 
> #
> ...

 

apache2ctl -S reports this:

 *Quote:*   

> 
> 
> [Sat Mar 11 09:29:29 2006] [warn] NameVirtualHost *:80 has no VirtualHosts
> 
> VirtualHost configuration:
> ...

 

What do I have configured wrong that is causing these [warn] messages?

----------

## adaptr

Tip #1: set -D DEFAULT_VHOST in /etc/conf.d/apache2

Tip #2: Do NOT define NameVirtualHost more than once

----------

