Re: [vserver] IPv6 in dualstack breaks IPv4 loopback virtualisation

From: Bruno Prémont <bonbons_at_linux-vserver.org>
Date: Thu 09 Sep 2010 - 18:17:15 BST
Message-ID: <20100909191715.2c203887@neptune.home>

Hi Oliver,

You mean that enabling IPv6 causes your apache (on host or inside guest?)
to see the guests real address?

My best bet, if without IPv6 it doesn't happen is that your apache is
listening on a mixed (IPv4 & IPv6)-any socket and over most of the place
the IPv4 localhost address of your wget is stored as IPv6 mapped IPv4
address and thus forgotten to get rewritten back to 127.0.0.1.

Could you tell us which kernel+patch version you are using and if letting
apache listen on IPv4-only and IPv6-only sockets makes wget's IP address
show up as expected?

Best regards,
Bruno

On Thu, 09 September 2010 cryptronic <mail@cryptronic.de> wrote:
> Hi all,
>
> i have problems using an dual stack setup in guest:
>
> ping localhost and 127.0.0.1 results as expected in return from 127.0.0.1
>
> Iif i try using wget on localhost
>
> # wget localhost
> --2010-09-09 16:57:07-- http://localhost/
> Resolving localhost... 127.0.0.1, ::1
> Connecting to localhost|127.0.0.1|:80... connected.
> HTTP request sent, awaiting response... 200 OK
> Length: 45 [text/html]
> Saving to: `index.html'
>
> 100%[=======================>] 45 --.-K/s in 0s
>
> 2010-09-09 16:57:07 (5.93 MB/s) - `index.html' saved [45/45]
>
> i get the expected file but in my apache access log the real localhost
> adress is being displayed:
>
> 127.27.114.1 - - [09/Sep/2010:16:57:07 +0000] "GET / HTTP/1.0" 200 45
> "-" "Wget/1.11.4"
>
> Is there a need for an ipv6 loopback virtualization?
>
> If I'm using apache in ipv4 only mode i got the old expected behaviour:
>
> 127.0.0.1 - - [09/Sep/2010:16:59:06 +0000] "GET / HTTP/1.0" 200 45 "-"
> "Wget/1.11.4"
>
> Best regards
>
> Oliver
Received on Thu Sep 9 18:18:57 2010

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Thu 09 Sep 2010 - 18:18:57 BST by hypermail 2.1.8