We help IT Professionals succeed at work.
Get Started

Apache on Windows Vista -- virtual hosts STILL not working!

Last Modified: 2012-05-07
installed Apache 2.2 on Windows Vista

Last night, I thought we'd gotten virtual hosts working, because with the latest change, http://BlackLocustSoftware.bls took me to the right spot.

Today I added more virtual hosts ... and they all took me to the directory for the first virtual host in the list.  I then tested and found that was now taking me that folder as well, not my basic Websites folder.

I would MUCH appreciate somebody helping me get this thing right!

Attaching httpd.conf ...
ServerRoot "C:/Program Files (x86)/Apache Software Foundation/Apache2.2"
Listen 80
LoadModule actions_module modules/mod_actions.so
LoadModule alias_module modules/mod_alias.so
LoadModule asis_module modules/mod_asis.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule authn_default_module modules/mod_authn_default.so
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authz_default_module modules/mod_authz_default.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule cgi_module modules/mod_cgi.so
LoadModule dir_module modules/mod_dir.so
LoadModule env_module modules/mod_env.so
LoadModule include_module modules/mod_include.so
LoadModule isapi_module modules/mod_isapi.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule mime_module modules/mod_mime.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule setenvif_module modules/mod_setenvif.so
<IfModule !mpm_netware_module>
<IfModule !mpm_winnt_module>
User daemon
Group daemon
ServerAdmin Daniel.Wilson@BlackLocustSoftware.com
DocumentRoot "D:/Business/WilliamstonConsulting/Websites/"
<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
<Directory "D:/Business/WilliamstonConsulting/Websites/">
    Options Indexes FollowSymLinks
    AllowOverride None
    Order allow,deny
    Allow from all
<IfModule dir_module>
    DirectoryIndex index.php index.html
<FilesMatch "^\.ht">
    Order allow,deny
    Deny from all
    Satisfy All
ErrorLog "logs/error.log"
LogLevel debug
<IfModule log_config_module>
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common
    <IfModule logio_module>
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
    CustomLog "logs/access.log" common
<IfModule alias_module>
    ScriptAlias /cgi-bin/ "C:/Program Files (x86)/Apache Software Foundation/Apache2.2/cgi-bin/"
<IfModule cgid_module>
<Directory "C:/Program Files (x86)/Apache Software Foundation/Apache2.2/cgi-bin">
    AllowOverride None
    Options None
    Order allow,deny
    Allow from all
DefaultType text/plain
<IfModule mime_module>
    TypesConfig conf/mime.types
    AddType application/x-compress .Z
    AddType application/x-gzip .gz .tgz
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
## Virtual Hosts -- configure these in HOSTS file!
NameVirtualHost *:80
<VirtualHost BlackHistoryReview.BLS>
 ServerName BlackHistoryReview.BLS
 ServerAdmin Daniel.Wilson@BlackLocustSoftware.com
 DocumentRoot "D:/Business/WilliamstonConsulting/Websites/BHR"
<VirtualHost BlackLocustSoftware.BLS>
 ServerName BlackLocustSoftware.BLS
 ServerAdmin Daniel.Wilson@BlackLocustSoftware.com
 DocumentRoot "D:/Business/WilliamstonConsulting/Websites/WC"
<VirtualHost ChainsWeCanBelieveIn.BLS>
 ServerName ChainsWeCanBelieveIn.BLS
 ServerAdmin Daniel.Wilson@BlackLocustSoftware.com
 DocumentRoot "D:/Business/WilliamstonConsulting/Websites/Chains"
<VirtualHost JohnScottUpholstery.BLS>
 ServerName JohnScottUpholstery.BLS
 ServerAdmin Daniel.Wilson@BlackLocustSoftware.com
 DocumentRoot "D:/Business/WilliamstonConsulting/Websites/JohnScottUpholstery"
PHPIniDir "C:/Program Files (x86)/PHP/"
LoadModule php5_module "C:/Program Files (x86)/PHP/php5apache2_2.dll"

Open in new window

Watch Question
This problem has been solved!
Unlock 1 Answer and 7 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE