Closed Thread Icon

Preserved Topic: vhosts on win2k (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=21180" title="Pages that link to Preserved Topic: vhosts on win2k (Page 1 of 1)" rel="nofollow" >Preserved Topic: vhosts on win2k <span class="small">(Page 1 of 1)</span>\

 
butcher
Paranoid (IV) Inmate

From: New Jersey, USA
Insane since: Oct 2000

posted posted 02-04-2002 19:31

Okay... Now I'm starting to get pissed! I can't for the life of me figure out how to get vhosts working on my local server.

I've made a C:\WINDOWS\HOSTS file like this:

127.0.0.1 localhost test1.local.com test2.local.com

I have made what I believe to be the proper changes to my httpd.conf file:

  1. ServerName 127.0.0.1
  2. UseCanonicalName Off
  3. NameVirtualHost 127.0.0.1
  4. <VirtualHost 127.0.0.1>

    DocumentRoot C:\FoxServ/www/test1.local

    ServerName test1.local.com

    </VirtualHost>



    <VirtualHost 127.0.0.1>

    DocumentRoot C:\FoxServ/www/test2.local

    ServerName test2.local.com

    </VirtualHost>



I also have the directories test1.local and test2.local within the www directory. When I type http://test1.local.com/index.html I get a blank page, and the icon in the taskbar says "Can't find server".

Could someone please enlighten me as to what I may be missing?

Everything I read says this is so easy!! How stupid can I be?

Thanks

-Butcher-

[This message has been edited by butcher (edited 02-04-2002).]

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 02-04-2002 19:47

I can't tell on the apache side of things but I'd start with the name stuff

The actual name of the local file should be "lmhosts" and actually goes in a different spot on 2K. There should be an unused sample file there already

http://support.microsoft.com/default.aspx?scid=kb;EN-US;q180094

That article should help.



:[ Computers let you make more mistakes faster than any other invention in human history, with the possible exceptions of handguns and tequila. ]:

[This message has been edited by bitdamaged (edited 02-04-2002).]

butcher
Paranoid (IV) Inmate

From: New Jersey, USA
Insane since: Oct 2000

posted posted 02-04-2002 20:20

Thanks for the link Bitdamaged!

It looks like your probably right about the lmhosts file, but I looked at the info in the sample file and read the stuff at the link you gave me, and now I'm even more confused. I just started to think I was getting a handle on what to do in the Apache config file and now the syntax of the lmhosts file has me even more baffled.

Thanks again for your help, I'm off to do more research!

-Butcher-

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 02-04-2002 20:29

This is what I use in my lmhosts file just to point to another box by name instead of IP
It lives at C:\WINDOWS\SYSTEM32\DRIVERS\etc\lmhosts

10.100.xxx.x bitdamaged #PRE #DOM



:[ Computers let you make more mistakes faster than any other invention in human history, with the possible exceptions of handguns and tequila. ]:

butcher
Paranoid (IV) Inmate

From: New Jersey, USA
Insane since: Oct 2000

posted posted 02-04-2002 20:45

I got it!!!

Just for the heck of it, I looked at the hosts file in the same ect directory. I don't quite know what the difference is, but when i added the two vhosts to that file like so:

127.0.0.1 test1.local.com
127.0.0.1 test2.local.com

And it works like a charm!

Thanks again Bitdamaged!!

-Butcher-

« BackwardsOnwards »

Show Forum Drop Down Menu