Apache 2 startup warning: NameVirtualHost *:80 has no VirtualHosts-Collection of common programming errors
Change
to read
Or its (NameVirtualHost *:80) added twice in your apache2 Confing file. ( By Default its added in ports.conf file )
This should clear the error.
Aside: you shouldn’t ignore this error. Apache’s config, especially when globbing virtual hosts (eg Include /etc/httpd/vhosts.d/*) is not stable. That means you don’t control the order of loading the hosts explicitly so the default vhost for an IP becomes the one that is loaded first, which can lead to unintended consequences.
One example of this is the default vhost for an IP will also be available on that IP, rather than its name. This can cause information to leak onto google referring to your sites IP rather than name, which can be confusing for customers.
The NameVirtualHost error above can be a hint that apache has loaded things in a non optimal way, so you shouldn’t ignore it.