From e88b6e38beddf8238cb8f31f0b0e35551f1c8ed9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Fri, 28 Mar 2014 02:57:12 +0100 Subject: [PATCH] network: suppress NetworkManager from touching inter-vm interfaces (#774) Those interfaces are configured by qubes scripts (based on xenstore data filled by qubes core). --- network/network-manager-prepare-conf-dir | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/network/network-manager-prepare-conf-dir b/network/network-manager-prepare-conf-dir index bfb6dee..1704b01 100755 --- a/network/network-manager-prepare-conf-dir +++ b/network/network-manager-prepare-conf-dir @@ -8,4 +8,11 @@ if [ -d $NM_CONFIG_DIR -a ! -h $NM_CONFIG_DIR ]; then ln -s /rw/config/NM-system-connections $NM_CONFIG_DIR fi +# Do not manage xen-provided network devices +unmanaged_devices=mac:fe:ff:ff:ff:ff:ff +for mac in `xenstore-ls device/vif | grep mac | cut -d= -f2 | tr -d '" '`; do + unmanaged_devices="$unmanaged_devices;mac:$mac" +done +sed -i -e "s/^unmanaged-devices=.*/unmanaged-devices=$unmanaged_devices/" /etc/NetworkManager/NetworkManager.conf + exit 0