Пытаюсь тут поднять на серваке виртуалку. Все происходит под ubuntu 12.10. Вот /etc/network/interfaces
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet manual
auto br0
iface br0 inet static
address 192.168.2.251
netmask 255.255.255.0
network 192.168.2.0
broadcast 192.168.2.255
gateway 192.168.2.1
dns-nameservers 192.168.2.1
dns-search simicon
bridge_ports eth0
# bridge_stp on
# bridge_maxwait 0
bridge_fd 9
bridge_hello 2
bridge_maxage 12
Виртуалку поднимаю вот так:
sudo kvm -boot c -m 2048 -hda /home/user/some.qcow2 -net nic,vlan=0,macaddr=53:55:01:13:35:52,model=e1000 -net tap,vlan=0,ifname=tap0,script=/etc/qemu-ifup_new -vnc :1 -usb
Вот /etc/qemu-ifup_new
#!/bin/sh
echo "Executing /etc/qemu-ifup"
echo "Bringing up $1 for bridged mode..."
/sbin/ifconfig $1 0.0.0.0 promisc up
echo "Adding $1 to br0..."
/sbin/brctl addif br0 $1
sleep 2
Вот вывод ifconfig на серваке:
br0 Link encap:Ethernet HWaddr 00:23:54:f3:3c:50
inet addr:192.168.2.251 Bcast:192.168.2.255 Mask:255.255.255.0
inet6 addr: fe80::223:54ff:fef3:3c50/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:38582 errors:0 dropped:0 overruns:0 frame:0
TX packets:14367 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:2339076 (2.3 MB) TX bytes:31240970 (31.2 MB)
eth0 Link encap:Ethernet HWaddr 00:23:54:f3:3c:50
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:126307 errors:0 dropped:0 overruns:0 frame:0
TX packets:14367 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:13360920 (13.3 MB) TX bytes:31240970 (31.2 MB)
Interrupt:16
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:41 errors:0 dropped:0 overruns:0 frame:0
TX packets:41 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:3360 (3.3 KB) TX bytes:3360 (3.3 KB)
tap0 Link encap:Ethernet HWaddr fe:f1:e6:c2:9b:56
inet6 addr: fe80::fcf1:e6ff:fec2:9b56/64 Scope:Link
UP BROADCAST RUNNING PROMISC MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:1 carrier:0
collisions:0 txqueuelen:500
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Вот, что на виртуалке. http://rghost.ru/44118293 Как правильно настроить сеть в виртуалке?