KVM的安装和使用(多Guest OS支持)for Ubuntu
时间:2010-11-14 来源:williamyoung
区别一:所需的安装包
qemu-kvm |
区别二:网络配置文件
#/etc/network/interfaces
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet manual
auto tap0
iface tap0 inet manual up
ifconfig $IFACE 0.0.0.0 up
down ifconfig $IFACE down
tunctl_user yourusername
auto tap1
iface tap1 inet manual up
ifconfig $IFACE 0.0.0.0 up
down ifconfig $IFACE down tunctl_user yourusername
auto br0 iface br0 inet dhcp
bridge_ports eth0 tap0
bridge_stp off
bridge_fd 0 bridge_maxwait 0
#如果是表态,用以下方式 #iface br0 inet static
#address 192.168.1.2
#netmask 255.255.255.0 #gateway 192.168.1.1 |
Troubleshooting
Warning: could not open /dev/net/tun: no virtual network emulation通过
ls -l /dev/net/tun |
发现有这个设备
crw-rw---- 1 root uml-net 10, 200 2010-10-24 19:44 /dev/net/tun |
chmod o+rw /dev/net/tun |