...

View Full Version : virtual hosts(aint they a *****?)



GO ILLINI
07-20-2006, 06:29 AM
NameVirtualHost *

<VirtualHost *>
ServerName adamsworld.name
DocumentRoot C:/server/xampp/htdocs/
</VirtualHost>
<VirtualHost *:81>
ServerName cfg.adamsworld.name
DocumentRoot C:/server/xampp/htdocs/cfg
</VirtualHost>
That returns no errors(eg apache can start) but I still cant connect to adamsworld.name:81. in firefox "The connection has timed out"
IE freezes for a bit then gives me a blank page. What am i doing wrong?

-ILLINI

paulq
07-20-2006, 06:39 PM
Apache Documentation (http://httpd.apache.org/docs/1.3/vhosts/examples.html#port).

oracleguy
07-20-2006, 07:16 PM
And I assume you have apache setup to listen on port 80 and 81?

GO ILLINI
07-20-2006, 10:20 PM
it seems apparent that that is my problem.
I didnt know you were allowed to ahve more then one listen. I thought taht the virtual host acted like a listen. Havent got arround to testing it though...


-ILLINI

GO ILLINI
07-20-2006, 11:03 PM
NOGO

I have



Listen 80
Listen 81
--and--
NameVirtualHost *

<VirtualHost *:81>
ServerName cfg.adamsworld.name
DocumentRoot C:/server/xampp/htdocs/cfg
</VirtualHost>


now just regular adamsworld.name is gone to be replaced by that.

firepages
07-22-2006, 02:33 AM
have you set an entry in the windows host file to tell windows that cfg.adamsworld.name is served by localhost ?

example hosts file entry (c:/windows/system32/drivers/etc/hosts)

127.0.0.1 localhost
127.0.0.1 cfg.adamsworld.name

thats unless you run your own local DNS server etc

GO ILLINI
07-23-2006, 03:40 AM
my server is different from the computer I work at.
I thought that the hosts file was internal only. But would that work? ill try it.

firepages
07-23-2006, 03:47 AM
the hosts file overrides all DNS (thats why spyware tends to infect it with fake entries) if your server/network has a DNS server then you dont need the hosts file entry... but it is foolproof for testing)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum