[libvirt] [PATCH 2/5] Avoid reporting an error if veth device is already deleted

Eric Blake eblake at redhat.com
Wed Oct 2 20:40:17 UTC 2013


On 10/02/2013 05:31 AM, Daniel P. Berrange wrote:
> From: "Daniel P. Berrange" <berrange at redhat.com>
> 
> The kernel automatically destroys veth devices when cleaning
> up the container network namepace. During normal shutdown, it

s/namepace/namespace/

> is thus likely that the attempt to run 'ip link del vethN'
> will fail. If it fails, check if the device exists, and avoid
> reporting an error if it has gone. This switches to use the
> virCommand APIs instead of virRun too.
> 
> Signed-off-by: Daniel P. Berrange <berrange at redhat.com>
> ---
>  src/util/virnetdevveth.c | 17 ++++++++++++++---
>  1 file changed, 14 insertions(+), 3 deletions(-)

ACK.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 621 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20131002/e62f4a99/attachment-0001.sig>


More information about the libvir-list mailing list