[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] How to disconnect a NIC



Hi,

some time ago I wrote I patch to change the source bridge of a running domain. Now I'm wondering what's the best way to disconnect a NIC. My first thought was to set virDomainNetDef.data.bridge.brname to NULL. There are quite some places in the code that had to be modified to support this, but that should be doable. Another idea is to create a new interface type 'disconnected'. The purpose of this type would be specifying NICs (whose link state is either up or down) without any network connectivity. The type of this interface had to be changeable while the domain is running.

Any thoughts would greatly appreciated.

Hendrik Schwartke



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]