[CentOS-virt] Discover what vnet is attached to a kvm guest
centos.admin at gmail.com
Fri May 13 07:32:18 EDT 2011
On 5/13/11, carlopmart <carlopmart at gmail.com> wrote:
> Hi all,
> How can I see what vnet is attached to a certain kvm guest?? For
> example: I have a kvmguest1. When I launch this guest with virsh
> command, virsh creates a new vnetX interface for this guest. How can I
> extract this virtual net interface (vnet0, vnet1, vnet2 or so on) using
> a script??
If I'm not mistaken, this is automatically assigned. However, you
could define this in the domain XML using the target tag within the
interface container, e.g. using the libvirt example
>From there, I suppose you could extract the information from the
relevant xml with your script.
More information about the CentOS-virt