这是使用 qemu-kvm 管理工具创建的配置文件的片段。如何使用 VMM 或 virsh 创建相同的配置?
[net]
type = "nic"
[net]
type = "tap"
script = "/etc/ovs-ifup"
downscript = "/etc/ovs-ifdown"
This configuration file indicates that you're using OpenVSwitch to manage virtual network ports for you KVM virtual machines.
Refer to this article for howtos and how it creates/destroy virtual network ports.
You can use this command to create and then enable new tap device vnetX
:
ip tuntap add dev vnetX mode tap
ip link set up dev vnetX