From d6432a16c48ab12f3458c6b367cc8ed2de221701 Mon Sep 17 00:00:00 2001 From: Alexandre Bezroutchko Date: Thu, 18 Oct 2012 06:30:47 +0200 Subject: [PATCH] dom0/qvm-tools: clean resolv.conf when networking goes down --- dom0/qvm-tools/qubes-dom0-network-via-netvm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dom0/qvm-tools/qubes-dom0-network-via-netvm b/dom0/qvm-tools/qubes-dom0-network-via-netvm index ab4eb456..0e8047e8 100755 --- a/dom0/qvm-tools/qubes-dom0-network-via-netvm +++ b/dom0/qvm-tools/qubes-dom0-network-via-netvm @@ -75,6 +75,8 @@ def netdown(): if not vif_eth0_exists(): print >> sys.stderr, 'There is no eth0 that is a Xen vif device, aborting.' sys.exit(1) + resolv_conf = open('/etc/resolv.conf', "w") + resolv_conf.close() os.system('ifconfig eth0 down') os.system('xl network-detach 0 0')