Page is a not externally linkable
dingman - 5:02 am on Nov 1, 2002 (gmt 0)
When mixing and matching NameVirtualHost and VirtualHost directives, you have to set one IP aside for the NameVirtualHosts. Set that IP as the default for IP VirtualHosts. Then set up a NameVirtualHost on that ip for the name or names that are supposed to be served by the IP, and a default NameVirtualHost with some content letting visitors know that the domain they are looking for moved. Perhaps a cutom 404? Like I said, it's been a while since I did this, so I may have forgotten an important detail or three. If you decide to use the <VirtualHost *> approach, make sure that you check the Apache docs to confirm whether that should be the first or the last vhost - I could easily immagine that the first listed matching host would serve every request, in which case having <VirtualHost *> at the top could make all other vhosts stop working.
It's been a while since I actually did this, so I may have forgotten the details. However, I think the solution you need is a combination of IP-based virtual hosts and name-based virtual hosts.