wood burning stoves 2.0*
The moose likes Tomcat and the fly likes Help w/ Apache Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Help w/ Apache" Watch "Help w/ Apache" New topic
Author

Help w/ Apache

Dustin Eldridge
Greenhorn

Joined: Feb 04, 2008
Posts: 20
Help I cannot seem to make my server see two websites. I have to domain names that both point to the same ip address so I went into the config file and tried to set up the config file in Apache to no avail here is the virtual host part. What am I doing wrong/ when I type in the ozarkaeology.com in the browser it just dumps me out at our joplinstockyards.com homepage?

Apache Config file:

### Section 3: Virtual Hosts
#
# VirtualHost: If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs-2.0/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.

#
# Use name-based virtual hosting.
#
NameVirtualHost *:80

#
# 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.
#
#<VirtualHost *:80>
# ServerAdmin webmaster@dummy-host.example.com
# 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
#</VirtualHost>


<VirtualHost *:80>
ServerAdmin dusty@joplinstockyards.com
DocumentRoot "C:/Program Files/Apache Group/Apache2/htdocs/"
ServerName "www.joplinstockyards.com"
ErrorLog "logs/joplinstockyards.com-error_log"
# CustomLog "logs/joplinstockyards.com-access_log common"
</VirtualHost>

<VirtualHost *:80>
ServerAdmin admin@ozarkaeology.com
DocumentRoot "C:/Program Files/Apache Group/Apache2/htdocs2/"
ServerName "www.ozarkaeology.com"

</VirtualHost>
Dustin Eldridge
Greenhorn

Joined: Feb 04, 2008
Posts: 20
Fixed now.
Tore Sagen
Greenhorn

Joined: Apr 23, 2004
Posts: 18
It would be nice of you to post the solution too. Others may encounter the same problem and come here for help (like you did).
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Help w/ Apache
 
Similar Threads
Request to Tomcat from remote machine
virtual hosts
Apache Server doubt
configuring ssl for apache+openssl+tomcat
Apache HTTP Server is not responding on 100 User Load