[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: New VHosts in apache 1.3



This looks correct. Note that this will not work for web browsers which don't
comply with HTTP 1.1. Ie., the client is required to send the "Host:" header in
the request, which wasn't done in HTTP 1.0. Which browsers send the header? I
leave this as an exercise for the reader. If you have a client that doesn't seem
to be working you can do a test like this: install the "netcat" package if you
don't already have it. Now on your linux box run:

nc -l -p 9000

And on the client type in the  URL "http://your.server.name:9000"; where
'your.server.name' is the fqdn of the linux box. nc will spit out all the headers
the browser's sending. For example, when I try this test using my Netscape 4.05
browser from NT to my linux box I get:

chilin$ nc -l -p 9000
GET / HTTP/1.0
Connection: Keep-Alive
User-Agent: Mozilla/4.05 [en] (WinNT; I)
Host: chilin:9000
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, image/png, */*
Accept-Language: en
Accept-Charset: iso-8859-1,*,utf-8

Asher Haig wrote:

> How do I set up the vhost in apache 1.3? The way I have it set up right
> now, they just send it to the first one, regardless of all the others.
> I'm doing name based rather than IP based.
>
> After looking at the documentation, here's what I have:
>
> NameVirtualHost 168.151.130.19
>
> <VirtualHost 168.151.130.19>
> ServerAdmin aaron@radix.net
> DocumentRoot /home/.aaron/houreyes
> ServerName www.houreyes.com
> ErrorLog /var/log/www/houreyes.com.err
> TransferLog /var/log/www/houreyes.com.trn
> </VirtualHost>
>
> <VirtualHost 168.151.130.19>
> ServerAdmin ahaig@warped-reality.com
> DocumentRoot /home/.lordwurm/public_html
> ServerName wurmland.warped-reality.com
> ErrorLog /var/log/www/wurmland.warped-reality.com.err
> TransferLog /var/log/www/wurmland.warped-reality.com.trn
> </VirtualHost>
>
>    =--------------------------------------------=
>    | Asher Haig        ahaig@warped-reality.com |
>    | Pager/Voice Mail              (972) 328-9247 |
>    =--------------------------------------------=
> "It was like a visit by Don Carleone. I expected to
> find a bloody computer monitor in my bed the next day."
> -- Mark Andreessen regarding the visit from Microsoft.
>
> --
> To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



--
Jens B. Jorgensen
jjorgens@bdsinc.com



--
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


Reply to: