Re: [Vserver] BIND (named) and "lo" interface inside vserver

From: Herbert Poetzl <herbert_at_13thfloor.at>
Date: Wed 16 Nov 2005 - 01:17:30 GMT
Message-ID: <20051116011730.GC26875@MAIL.13thfloor.at>

On Tue, Nov 15, 2005 at 11:01:22PM +0300, Dmitry Koterov wrote:
> >> > Shortly: when I use BIND (or PowerDNS) inside vserver listening
> >> > ALL addresses (0.0.0.0), nslookup to server 127.0.0.1 shows error
> >> > message "reply from unexpected source: 213.248.62.106#53,
> >> > expected 127.0.0.1#53"
>
> >> Which is true, as your nameserver (powerdns or bind) is assigned
> >> your vserver interface as primary interface and answers are sent with
> >> that source.
>
> Very strange. In other machine (non-virtual) BIND answers from
> that interface which was used to pass query to. If I say in
> nslookup:
>
> server 127.0.0.1
>
> answer goes from 127.0.0.1, and if I say
>
> server aaa.bbb.ccc.ddd
>
> (same machine), it goes from aaa.bbb.ccc.ddd.

yes, because 127.0.0.1 is not remapped ...

> > hmm, let me rephrase this: in a guest (with current networking)
> > the localhost ip 127.0.0.1 is remapped to the first assigned
> > guest IP (which is very likely 213.248.62.106 in your case)
>
> Maybe you know, how can I bring up OWN 127.0.0.1 in EACH virtual
> machines, independent to other virtual machines?

yes, I know, but it involves modifying the kernel :)

> > > [root@zulu /]# ifconfig
> >> > eth0 Link encap:Ethernet HWaddr 00:30:48:75:13:D2
> >> > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> >> > RX packets:39623139 errors:0 dropped:0 overruns:0 frame:0
> >> > TX packets:18575687 errors:0 dropped:0 overruns:0 carrier:0
> >> > collisions:0 txqueuelen:1000
> >> > RX bytes:50148146621 (46.7 GiB) TX bytes:1249870165 (1.1 GiB)
> >> > Base address:0x3000 Memory:dd300000-dd320000
> >> >
> >> > eth0:zulu Link encap:Ethernet HWaddr 00:30:48:75:13:D2
> >> > inet addr:213.248.62.106 Bcast:213.248.62.255 Mask:255.255.255.0
> >> > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> >> > Base address:0x3000 Memory:dd300000-dd320000
> >> >
> >> > First question: why doesn't ifconfig show "lo" interface?
> >> > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> >> lo is not assigned to your context and therefor not shown.
>
> > there is no IP assigned which would 'refer' to lo, so as
> > lo is not carrying any visible IP it is not shown
> > (you can make all interfaces visible by disabling the
> > hide_netif flag)
>
> I need not "all visible and shared between vservers" interfaces,
> but - own 127.0.0.1 in each vserver, independently.

no, you _want_ such a thing, you do not need it :)

> > here it is: linux-networking does not depend/operate on
> > interfaces but on IPs, so the guests are not 'limited' to
> > interfaces but a subset of the host IPs ...
> > (in your case very likely a single one, 213.248.62.106)
> Yes, 213.248.62.106 specified in
> /etc/vservers/zulu/interfaces/00/ip
> - and no other IPs and interfaces.
>
> >> > Seems networking stack isolation in linux-vserver is not finished
> >> > yet?
>
> >> I don't know the answer to this one, but it seems that it is doing
> >> its job quite nicely ;)
>
> > we intentionally avoided further IP stack isolation,
> > because naturally this adds overhead we want to avoid
>
> > nevertheless, we are working on an alternative solution
> > (code name NGNET) which will provide complete network
> > virtualization for those who really need it ...
>
> I only want vserver to be used as usual, non-virtual machine with
> all applications. Today result - I cannot use BIND as usual.

not with the configurations for non-virtual machines
you have to use Xen, UML, QEMU or BOCHS to do that,
or to simply adapt the config ...

> Please tell if you have a solution?.

just change 127.0.0.1 to your first guest IP in your
config files, and everything should work fine ...

HTH,
Herbert

> _______________________________________________
> Vserver mailing list
> Vserver@list.linux-vserver.org
> http://list.linux-vserver.org/mailman/listinfo/vserver
_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Wed Nov 16 01:17:50 2005

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Wed 16 Nov 2005 - 01:17:53 GMT by hypermail 2.1.8