[Vserver] Re: using djbdns (tinydns & dnscache) from within vserver

From: Benedict Verheyen <linux4bene_at_telenet.be>
Date: Fri 14 Apr 2006 - 00:39:10 BST
Message-ID: <443EE11E.3060900@telenet.be>

<snip>

Hi,

I removed the bridge and stopped the remaining UML because i thought
that bridging might be causing an error.
The host machine has 2 nic's and the first, eth0 has an ip 192.168.0.2
and is connected to the net via a wireless bridge to wireless router to
cablemodem setup. eth1 has an ip 192.168.1.1 and is connected to the LAN.

The vserver starts but dns and ping don't work from inside de vserver:

ping localhost
PING localhost (127.0.0.1) 56(84) bytes of data.

--- localhost ping statistics ---
2 packets transmitted, 0 received, 100% packet loss, time 1010ms

This is the result of netstat -ua inside the vserver when it's not working:

Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State
udp 0 0 192.168.1.20:domain *:*
udp 0 0 192.168.1.20:domain *:*
udp 0 0 192.168.1.20:domain *:*
udp 0 0 192.168.1.20:20416 192.168.1.20:domain
ESTABLISHED
udp 0 0 192.168.1.20:10817 192.168.1.20:domain
ESTABLISHED
udp 0 0 192.168.1.20:24559 192.168.1.20:domain
ESTABLISHED

I can ping the ip of the vserver but not ping it by name.
I can also ping from within the vserver to the outside but again not by
name.

ifconfig from the host:
eth0 Link encap:Ethernet HWaddr 00:10:B5:40:DE:14
          inet addr:192.168.0.2 Bcast:192.168.0.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:8813 errors:0 dropped:0 overruns:0 frame:0
          TX packets:8022 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:3256901 (3.1 MiB) TX bytes:787578 (769.1 KiB)
          Interrupt:10 Base address:0x9400

eth1 Link encap:Ethernet HWaddr 00:10:B5:40:DD:EE
          inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:11828 errors:0 dropped:0 overruns:0 frame:0
          TX packets:13316 errors:0 dropped:0 overruns:0 carrier:0
          collisions:24 txqueuelen:1000
          RX bytes:1567772 (1.4 MiB) TX bytes:3817607 (3.6 MiB)
          Interrupt:11 Base address:0x9000

eth1:frey Link encap:Ethernet HWaddr 00:10:B5:40:DD:EE
          inet addr:192.168.1.22 Bcast:192.168.1.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          Interrupt:11 Base address:0x9000

eth1:loki Link encap:Ethernet HWaddr 00:10:B5:40:DD:EE
          inet addr:192.168.1.21 Bcast:192.168.1.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          Interrupt:11 Base address:0x9000

eth1:njor Link encap:Ethernet HWaddr 00:10:B5:40:DD:EE
          inet addr:192.168.1.23 Bcast:192.168.1.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          Interrupt:11 Base address:0x9000

eth1:thor Link encap:Ethernet HWaddr 00:10:B5:40:DD:EE
          inet addr:192.168.1.20 Bcast:192.168.1.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          Interrupt:11 Base address:0x9000

lo Link encap:Local Loopback
          inet addr:127.0.0.1 Mask:255.0.0.0
          UP LOOPBACK RUNNING MTU:16436 Metric:1
          RX packets:17642 errors:0 dropped:0 overruns:0 frame:0
          TX packets:17642 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:2516560 (2.3 MiB) TX bytes:2516560 (2.3 MiB)

First i set the vserver up to use an interface set up under dir 0 and
with a device name eth0 but then you get a 192.168.1.x adres on a
192.168.0.x nic (eth0) and that didn't seem correct so i changed that to
dir 1 and eth1.

Also, when i put raw_icmp inside the ccapabilities file, i get an error
when starting the vserver:
================ ERROR ================
Unknown ccap 'raw_icmp'

An error occured while executing the vserver startup sequence; when
there are no other messages, it is very likely that the init-script
(/etc/init.d/rc 2) failed.

Common causes are:
* /etc/rc.d/rc on Fedora Core 1 and RH9 fails always; the 'apt-rpm'
build method knows how to deal with this, but on existing installations,
 appending 'true' to this file will help.

Failed to start vserver 'thor'
================ ERROR ================

Maybe util-vserver related? The version of util-vserver that i'm using
is 0.30.204

I then changed the ip of the vserver to 192.168.1.25 instead of
192.168.1.20, changed the /etc/resolv.conf of the host and then dns works.
I then moved the 1 dir back to 0, changed the dev back to eth0 and it
still worked.
But from the moment i changed the ip & resolv.conf back to 192.168.1.20
name resolving stopped working from the host. Inside the vserver it
still worked.

Any ideas?

Thanks
Benedict

_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Fri Apr 14 00:40:03 2006

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Fri 14 Apr 2006 - 00:40:08 BST by hypermail 2.1.8