On 1/2/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
On Tuesday 02 January 2007 07:44, [EMAIL PROTECTED] wrote:
> > After advice given here, but for other reasons too, I got a adsl-router
> > rather than an adsl-bridge to tigger.
> >
> > What I've lost is name virtual hosts. My router (dlink 604T) does
> > suitable virtual hosting, but all the necessary name information is lost
> > before it gets routed to apache2. ie router:80 -> 192.168.1.254:80
> >
> > Is there a way of hosting multiple sites with a router?
>
> Your router only forwards to addresses and ports. It knows nothing of the
> protocol you're forwarding.
>
> You most likely have a configuration issue on the machine behind your
> router. The *client* tells the web server which "Host" name it wants.
>
> Use telnet to check what your web server is doing:
>
> $ telnet perkypants.org 80
> Trying 70.85.31.216...
> Connected to perkypants.org.
> Escape character is '^]'.
> HEAD / HTTP/1.0
>
> HTTP/1.1 302 Found
> Date: Mon, 01 Jan 2007 02:18:17 GMT
> Server: Apache/2.0.55 (Ubuntu) PHP/5.1.2
> Location: http://waugh.id.au/
> Connection: close
> Content-Type: text/html; charset=iso-8859-1
>
> (As you can see above, my machine has a sensible default configuration for
> no-name requests, which instead of dumping a useless error, redirects to a
> relatively useful site.)
>
> Then, check what your web server is doing when the client is actually doing
> the right thing (specifically, the Host header):
>
> $ telnet perkypants.org 80
> Trying 70.85.31.216...
> Connected to perkypants.org.
> Escape character is '^]'.
> HEAD / HTTP/1.0
> Host: perkypants.org
>
> HTTP/1.1 200 OK
> Date: Mon, 01 Jan 2007 02:22:34 GMT
> Server: Apache/2.0.55 (Ubuntu) PHP/5.1.2
> Last-Modified: Sun, 17 Dec 2006 14:40:02 GMT
> ETag: "1973d-3ee-d711b480"
> Accept-Ranges: bytes
> Content-Length: 1006
> Connection: close
> Content-Type: text/html; charset=UTF-8

Jeff
thanks for the detailed reply.

When I had virtual hosts enabled on tigger, and tigger bridged to my ADSL:
http://tigger.ws                # was my page
http://margaret.tigger.ws       # was, what is now http://tigger.ws/margaret
http://deej.tigger.ws           # was, what is now http://tigger.ws/deej

With the router:
http://tigger.ws                # was my page
http://margaret.tigger.ws       # was still my page
http://deej.tigger.ws           # was still my page

Not to bad so far, but I want to host http://sunfeathers.net which is
http://tigger.ws/deej but sunfeathers.net is tigger.ws NOT tigger.ws/deej

Again, everything worked with tigger bridged to ADSL, but not virtual host on
router.

Is any of this useful, (from the internet, not from within)?
[server] /home/jam [891]% telnet tigger.ws 80
Trying 202.71.175.58...
Connected to tigger.ws.
Escape character is '^]'.

Ummm ?

This key is:

> Your router only forwards to addresses and ports. It knows nothing of the
> protocol you're forwarding.

If the router is addressed as tigger.ws, deej.tigger.ws or sunfeathers.net
it forwards the request to 192.168.5.254 and the same page is served.

Am I missing something ?
Thanks
James

I don't think so, you've given a quite detailed account of the
problem, the root cause of the problem, and the solution.

As you've described the router is doing a portforward at the TCP
level, where it can only look at IPs and port numbers. You only have
one IP, and only one port. Tigger used to do proxying at the HTTP
layer, where it was looking at the "HOST: " field of the HTTP request
- there can be lots of different "HOST: " fields.

You've already described the solution you had on the past: Tigger
obviously knows how to do the right proxying. Just get your router to
point to Tigger (or some similarly configured HTTP proxy, if Tigger
doesn't do what Tiggers do best any more) and everything should be
fine.
--
There is nothing more worthy of contempt than a man who quotes himself
- Zhasper, 2004
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Reply via email to