Antoni Segura Puimedon has posted comments on this change.
Change subject: Make nics, vlan and bonding dhcp ifup to be asynchronous.
......................................................................
Patch Set 2: (1 inline comment)
....................................................
File vdsm/configNetwork.py
Line 945: bondingOptions=bondingOptions,
Line 946: mtu=max(prevmtu, mtu),
Line 947: ipaddr=ipaddr, netmask=netmask,
Line 948: gateway=gateway, **options)
Line 949: bondBootproto = options.get('bootproto')
There is the step of setting options['bootproto'] to None after each
assignment, so that the dhcp will only be on the topmost interface. Like in
this example:
def foo(options, bridge, vlan, bonding):
if bridge:
bridgeB = options.get('boot')
options['boot'] = None
if vlan:
vlanB = options.get('boot')
options['boot'] = None
if bonding:
bondB = options.get('boot')
options['boot'] = None
print 'bridge: %s' % bridgeB
print 'vlan: %s' % vlanB
print 'bond: %s' % bondB
print 'nic: %s' % options['boot']
foo({'boot': 'dhcp'}, True, True, True)
that prints:
bridge: dhcp
vlan: None
bond: None
nic: None
Line 950: # reset ip, netmask, gateway and bootproto for lower level
devices
Line 951: ipaddr = netmask = gateway = options['bootproto'] = None
Line 952:
Line 953: for nic in nics:
--
To view, visit http://gerrit.ovirt.org/8098
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I80f5bbfe5ba4dfcf8f7f29c21a60b0cc2e129cb0
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Antoni Segura Puimedon <[email protected]>
Gerrit-Reviewer: Antoni Segura Puimedon <[email protected]>
Gerrit-Reviewer: Dan Kenigsberg <[email protected]>
Gerrit-Reviewer: Igor Lvovsky <[email protected]>
Gerrit-Reviewer: Mark Wu <[email protected]>
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches