Question : Apache Name Based Virutal Hosting Problem

I am using name based virtual hosting on 1 IP address the problem that I am having is when I go to the IP address which is: 67.207.142.156

It does not default to the default apache page that Centos has it defaults to the first website in the virtual host file.  Can anyone tell me why ?
Code Snippet:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
# Use name-based virtual hosting.
#
NameVirtualHost *:80
#
# NOTE: NameVirtualHost cannot be used without a port specifier
# (e.g. :80) if mod_ssl is being used, due to the nature of the
# SSL protocol.
#
 
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
#
#
#    ServerAdmin [email protected]
#    DocumentRoot /www/docs/dummy-host.example.com
#    ServerName dummy-host.example.com
#    ErrorLog logs/dummy-host.example.com-error_log
#    CustomLog logs/dummy-host.example.com-access_log common
#

        ServerName www.faderlaw.com
        DocumentRoot /home/faderlaw/website
        ErrorLog /home/faderlaw/logs/fader_logs

 

        ServerName www.ostashen-consulting.com
        #ServerAlias ostashen-consulting.net ostashen-consulting.org ostashen-consulting.biz ostashen-consulting.info ostashenconsulting.net ostashenconsulting.com ostashenconsulting.org ostashenconsulting.biz ostashenconsulting.info
        DocumentRoot /home/ostashenconsulting/website
        ErrorLog /home/ostashenconsulting/logs/ostashenconsulting_logs

 

        ServerName www.albertchin.com
        DocumentRoot /home/albertchin/website
        ErrorLog /home/albertchin/logs/albertchin_logs

Answer : Apache Name Based Virutal Hosting Problem

Just add default site as a first site in your virtual host file

And read documentation: http://httpd.apache.org/docs/2.2/vhosts/name-based.html
-------------------------------------------- cut -------------------------------------------
Main host goes away:
If you are adding virtual hosts to an existing web server, you must also create a block for the existing host. The ServerName and DocumentRoot included in this virtual host should be the same as the global ServerName and DocumentRoot. List this virtual host first in the configuration file so that it will act as the default host.
-------------------------------------------- cut -------------------------------------------
Random Solutions  
 
programming4us programming4us