From 44a2eba8d6c7a7ea9e78454388b859304398ec8d Mon Sep 17 00:00:00 2001
From: Igor Lvovsky <ilvovsky@redhat.com>
Date: Wed, 27 Jun 2012 10:37:28 +0300
Subject: [PATCH 22/25] BZ#835784 - Allow to create a network on top of
existing bond in additional to create a new bond and
network
If we already have a bond0 with (eth1, eth2) and now we want to create
network "bridge_woVlan" on top of it and in additional we want to create
a new bond1 with (eth3, eth4) and create a network "bridge_woVlan_2" on
top of bond 1.
This patch will allow us to do it in the same setupNetwork command.
Change-Id: I67d24d656934ea9dcb0a8209c6a375e19c23f82b
Signed-off-by: Igor Lvovsky <ilvovsky@redhat.com>
Reviewed-on: http://gerrit.ovirt.org/5737
Reviewed-on: http://gerrit.ovirt.org/5759
Reviewed-by: Dan Kenigsberg <danken@redhat.com>
Tested-by: Dan Kenigsberg <danken@redhat.com>
---
vdsm/configNetwork.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vdsm/configNetwork.py b/vdsm/configNetwork.py
index c535499..d4e1177 100755
--- a/vdsm/configNetwork.py
+++ b/vdsm/configNetwork.py
@@ -1085,7 +1085,7 @@ def setupNetworks(networks={}, bondings={}, **options):
if 'bonding' in d:
# we may not receive any information
# about the bonding device if it is unchanged
- if bondings:
+ if bondings.get(d['bonding']):
d['nics'] = bondings[d['bonding']]['nics']
d['bondingOptions'] = bondings[d['bonding']].get('options',
None)
--
1.7.10.2