---------- Forwarded message ----------
From: Julio César García Vizcaíno <jgarcia@xxxxxxx>
Date: 2010/6/25
Subject: No connection in DomUs with network-route
To: xen-users@xxxxxxxxxxxxxxxxxxx
Hi,
I would like to know if somebody can point me out how to configure
several DomUs in a private LAN (for example 192.168.100.0/24) and one
DomU with two interfaces (one - 192.168.100.0/24 and two - internet).
So far I have enabled in xend-config.sxp:
(network-script network-route)
(vif-script vif-route)
My config files have:
/mnt/VM/1.cfg:vif = ['ip=192.168.1.3']
/mnt/VM/2.cfg:vif = ['ip=192.168.1.4']
/mnt/VM/3.cfg:vif = ['ip=192.168.1.5']
debian:~# ifconfig
eth0 Link encap:Ethernet HWaddr 00:1a:a0:fc:9e:b1
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::21a:a0ff:fefc:9eb1/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:18374 errors:0 dropped:0 overruns:0 frame:0
TX packets:15903 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:15968912 (15.2 MiB) TX bytes:2638300 (2.5 MiB)
Interrupt:17
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
tap1.0 Link encap:Ethernet HWaddr de:48:4b:40:eb:0f
inet6 addr: fe80::dc48:4bff:fe40:eb0f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:24 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:2223 (2.1 KiB) TX bytes:368 (368.0 B)
tap2.0 Link encap:Ethernet HWaddr 12:a7:b2:a4:26:1c
inet6 addr: fe80::10a7:b2ff:fea4:261c/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:18 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:1863 (1.8 KiB) TX bytes:368 (368.0 B)
vif1.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
vif2.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
debian:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.100.3 0.0.0.0 255.255.255.255 UH 0 0 0 vif1.0
192.168.100.4 0.0.0.0 255.255.255.255 UH 0 0 0 vif2.0
192.168.1.200 0.0.0.0 255.255.255.255 UH 0 0 0 eth0
0.0.0.0 192.168.1.200 0.0.0.0 UG 0 0 0 eth0
debian:~# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere state
RELATED,ESTABLISHED PHYSDEV match --physdev-out vif2.0
ACCEPT udp -- anywhere anywhere PHYSDEV
match --physdev-in vif2.0 udp spt:bootpc dpt:bootps
ACCEPT all -- anywhere anywhere state
RELATED,ESTABLISHED PHYSDEV match --physdev-out vif2.0
ACCEPT all -- 192.168.100.4 anywhere PHYSDEV
match --physdev-in vif2.0
ACCEPT all -- anywhere anywhere state
RELATED,ESTABLISHED PHYSDEV match --physdev-out vif1.0
ACCEPT udp -- anywhere anywhere PHYSDEV
match --physdev-in vif1.0 udp spt:bootpc dpt:bootps
ACCEPT all -- anywhere anywhere state
RELATED,ESTABLISHED PHYSDEV match --physdev-out vif1.0
ACCEPT all -- 192.168.100.3 anywhere PHYSDEV
match --physdev-in vif1.0
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
debian:~# sysctl -p
net.ipv4.conf.default.rp_filter = 1
net.ipv4.ip_forward = 1
net.ipv6.conf.all.forwarding = 1
net.ipv4.icmp_echo_ignore_broadcasts = 1
net.ipv4.conf.default.proxy_arp = 1
+ ip route list
192.168.100.3 dev vif1.0 scope link src 192.168.1.10
192.168.100.4 dev vif2.0 scope link src 192.168.1.10
192.168.1.200 dev eth0 proto kernel scope link src 192.168.1.10
default via 192.168.1.200 dev eth0
mw-xen:~# xm info
host : debian
release : 2.6.32-bpo.4-xen-amd64
version : #1 SMP Thu Apr 8 13:20:53 UTC 2010
machine : x86_64
nr_cpus : 2
nr_nodes : 1
cores_per_socket : 2
threads_per_core : 1
cpu_mhz : 2194
hw_caps :
bfebfbff:20100800:00000000:00000940:0000e3bd:00000000:00000001:00000000
virt_caps : hvm
total_memory : 4046
free_memory : 2732
node_to_cpu : node0:0-1
node_to_memory : node0:2732
node_to_dma32_mem : node0:2732
max_node_id : 0
xen_major : 4
xen_minor : 0
xen_extra : .0
xen_caps : xen-3.0-x86_64 xen-3.0-x86_32p hvm-3.0-x86_32
hvm-3.0-x86_32p hvm-3.0-x86_64
xen_scheduler : credit
xen_pagesize : 4096
platform_params : virt_start=0xffff800000000000
xen_changeset : Wed Apr 07 12:37:57 2010 +0100 21089:484179b2be5d
xen_commandline : dom0_mem=1024M
cc_compiler : gcc version 4.3.2 (Debian 4.3.2-1.1)
cc_compile_by : root
cc_compile_domain : gateway.2wire.net
cc_compile_date : Wed Jun 23 04:06:21 IST 2010
xend_config_format : 4
mw-xen:~# ifconfig
eth0 Link encap:Ethernet HWaddr 00:1a:a0:fc:9e:b1
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::21a:a0ff:fefc:9eb1/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:20740 errors:0 dropped:0 overruns:0 frame:0
TX packets:17385 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:17263213 (16.4 MiB) TX bytes:2979154 (2.8 MiB)
Interrupt:17
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:45349 errors:0 dropped:0 overruns:0 frame:0
TX packets:45349 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:212182401 (202.3 MiB) TX bytes:212182401 (202.3 MiB)
tap1.0 Link encap:Ethernet HWaddr de:48:4b:40:eb:0f
inet6 addr: fe80::dc48:4bff:fe40:eb0f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:107 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:9639 (9.4 KiB) TX bytes:368 (368.0 B)
tap3.0 Link encap:Ethernet HWaddr 1a:55:ac:04:8b:67
inet6 addr: fe80::1855:acff:fe04:8b67/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:192 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:14739 (14.3 KiB) TX bytes:368 (368.0 B)
tap4.0 Link encap:Ethernet HWaddr 96:2c:b6:0f:77:6d
inet6 addr: fe80::942c:b6ff:fe0f:776d/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:445 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:29020 (28.3 KiB) TX bytes:368 (368.0 B)
tap5.0 Link encap:Ethernet HWaddr 82:35:3e:aa:d2:6f
inet6 addr: fe80::8035:3eff:feaa:d26f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:112 errors:0 dropped:0 overruns:0 frame:0
TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:8904 (8.6 KiB) TX bytes:438 (438.0 B)
tap6.0 Link encap:Ethernet HWaddr a6:0f:1f:2b:b5:d8
inet6 addr: fe80::a40f:1fff:fe2b:b5d8/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:472 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:36274 (35.4 KiB) TX bytes:368 (368.0 B)
vif1.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
vif3.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:5 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
vif4.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
vif5.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
vif6.0 Link encap:Ethernet HWaddr fe:ff:ff:ff:ff:ff
inet addr:192.168.1.10 Bcast:192.168.1.255 Mask:255.255.255.255
inet6 addr: fe80::fcff:ffff:feff:ffff/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
mw-xen:~# tcpdump -evvnni vif6.0
tcpdump: listening on vif6.0, link-type EN10MB (Ethernet), capture size 96 bytes
^C
0 packets captured
0 packets received by filter
0 packets dropped by kernel
mw-xen:~# tcpdump -evvnni tap6.0
tcpdump: WARNING: tap6.0: no IPv4 address assigned
tcpdump: listening on tap6.0, link-type EN10MB (Ethernet), capture size 96 bytes
02:54:08.808121 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:09.808058 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:10.810233 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:11.808055 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:12.808043 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:13.810491 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:14.808043 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:15.808113 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:16.810385 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:17.808047 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:18.808053 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:19.810181 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:20.808793 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:21.808074 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:22.810380 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:23.808077 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:24.808236 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:25.814274 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
02:54:26.808046 00:16:3e:2c:96:5d > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.2 tell 192.168.100.1
^C
19 packets captured
19 packets received by filter
0 packets dropped by kernel
mw-xen:~# tcpdump -evvnni tap5.0
tcpdump: WARNING: tap5.0: no IPv4 address assigned
tcpdump: listening on tap5.0, link-type EN10MB (Ethernet), capture size 96 bytes
02:54:37.471252 00:16:3e:5c:2a:c6 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.5
02:54:42.964490 00:16:3e:5c:2a:c6 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.5
02:54:48.465765 00:16:3e:5c:2a:c6 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.5
02:54:53.965331 00:16:3e:5c:2a:c6 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.5
^C
4 packets captured
4 packets received by filter
0 packets dropped by kernel
mw-xen:~# tcpdump -evvnni tap4.0
tcpdump: WARNING: tap4.0: no IPv4 address assigned
tcpdump: listening on tap4.0, link-type EN10MB (Ethernet), capture size 96 bytes
02:55:03.230195 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:04.231478 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:05.229952 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:06.229873 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:07.231859 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:08.229887 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:09.229911 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:10.231301 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
02:55:11.229969 00:16:3e:13:13:e0 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.2
^C
9 packets captured
9 packets received by filter
0 packets dropped by kernel
mw-xen:~# tcpdump -evvnni tap3.0
tcpdump: WARNING: tap3.0: no IPv4 address assigned
tcpdump: listening on tap3.0, link-type EN10MB (Ethernet), capture size 96 bytes
02:55:34.467072 00:16:3e:1f:d8:6e > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.4
02:55:39.964597 00:16:3e:1f:d8:6e > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.4
^C
2 packets captured
2 packets received by filter
0 packets dropped by kernel
mw-xen:~# tcpdump -evvnni tap1.0
tcpdump: WARNING: tap1.0: no IPv4 address assigned
tcpdump: listening on tap1.0, link-type EN10MB (Ethernet), capture size 96 bytes
02:55:49.964644 00:16:3e:71:ab:ef > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.4
02:55:55.468252 00:16:3e:71:ab:ef > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.4
02:56:00.964525 00:16:3e:71:ab:ef > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 60: arp who-has 192.168.100.3 tell 192.168.100.4
^C
3 packets captured
3 packets received by filter
0 packets dropped by kernel
If I put network-bridge my DomUs can get their IP from my DHCP server
and can talk each other but I should avoid this technique.
Thanks in advance.
--
Best regards,
Julio Cesar Garcia Vizcaino
M.Sc. Security & Forensic Computing (Attending), 2010 (DCU)
BEng Computer Engineering, 2008 (UNAM)
Selling and administration manager - SAFE
--
Best regards,
Julio Cesar Garcia Vizcaino
M.Sc. Security & Forensic Computing (Attending), 2010 (DCU)
BEng Computer Engineering, 2008 (UNAM)
Selling and administration manager - SAFE
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
|