Re: [users@httpd] Virtual Host Not Working

2014-02-12 Thread Jim Borland
My goodness, that worked!  I am blown away!  Thank you very much for 
your help with this.


Jim

On 2/12/2014 2:58 AM, Tom Evans wrote:

On Mon, Feb 10, 2014 at 10:24 PM, Jim Borland jborl...@calpoly.edu wrote:

My server, which is located in the Amazon cloud, was just moved to a new
location with a new IP address.  Nothing else was changed. However, the
Apache Virtual Host, which has worked flawlessly for several years, is
broken.  Apache server version is: Apache/2.2.16 (Ubuntu).

I went to my DNS host and changed the names to point to the new IP address.
But now, when I go to the hostname in my browser I end up at the default
site instead of the one specified for the virtual host.  Here is my config
file (httpd-vhosts.conf).




Simplify your config:


NameVirtualHost *:80

VirtualHost *:80
 ServerAdmin jborlan...@gmail.com
 ServerName ec2-75-101-136-229.compute-1.amazonaws.com
 DocumentRoot /var/www
/VirtualHost

Directory /home/jim
Order allow,deny
Allow from all
/Directory

VirtualHost *:80
 ServerName atascaderoband.org
 ServerAlias www.atascaderoband.org
 DocumentRoot /home/jim/atasband
/VirtualHost

VirtualHost *:80
 ServerName www.slocountyband.org
 ServerAlias slocountyband.org
 DocumentRoot /home/jim/band
/VirtualHost


Work now?

Cheers

Tom

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org





[users@httpd] Virtual Host Not Working

2014-02-10 Thread Jim Borland
My server, which is located in the Amazon cloud, was just moved to a new 
location with a new IP address.  Nothing else was changed. However, the 
Apache Virtual Host, which has worked flawlessly for several years, is 
broken.  Apache server version is: Apache/2.2.16 (Ubuntu).


I went to my DNS host and changed the names to point to the new IP 
address.  But now, when I go to the hostname in my browser I end up at 
the default site instead of the one specified for the virtual host.  
Here is my config file (httpd-vhosts.conf).




NameVirtualHost 75.101.136.229

VirtualHost 75.101.136.229
ServerAdmin jborlan...@gmail.com
ServerName ec2-75-101-136-229.compute-1.amazonaws.com
DocumentRoot /var/www
/VirtualHost

Directory /home/jim
   Order allow,deny
   Allow from all
/Directory

VirtualHost 75.101.136.229
ServerName atascaderoband.org
ServerAlias www.atascaderoband.org
DocumentRoot /home/jim/atasband
/VirtualHost

VirtualHost 75.101.136.229
ServerName www.slocountyband.org
ServerAlias slocountyband.org
DocumentRoot /home/jim/band
/VirtualHost



When I point my browser to atascaderoband.org or slocountyband.org I end 
up at: DocumentRoot /var/www instead of the ones specified for the two 
virtual hosts.


What really confuses me is that Apache says the virtual hosts are okay.  
When I type the command 'apachectl -S' I get this result:




# apachectl -S
VirtualHost configuration:
75.101.136.229:*   is a NameVirtualHost
   default server ec2-75-101-136-229.compute-1.amazonaws.com 
(/etc/apache2/sites-enabled/httpd-vhosts.conf:3)
   port * namevhost ec2-75-101-136-229.compute-1.amazonaws.com 
(/etc/apache2/sites-enabled/httpd-vhosts.conf:3)
   port * namevhost atascaderoband.org 
(/etc/apache2/sites-enabled/httpd-vhosts.conf:22)
   port * namevhost www.slocountyband.org 
(/etc/apache2/sites-enabled/httpd-vhosts.conf:31)

wildcard NameVirtualHosts and _default_ servers:
*:80   is a NameVirtualHost
   default server domU-12-31-39-04-58-57.compute-1.internal 
(/etc/apache2/sites-enabled/000-default:1)
   port 80 namevhost domU-12-31-39-04-58-57.compute-1.internal 
(/etc/apache2/sites-enabled/000-default:1)




Any thoughts or suggestions would be greatly appreciated.  Thank you!


-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org