Change in vdsm[master]: added mtu support for network interface

fsimonce at redhat.com fsimonce at redhat.com
Mon Jan 30 15:02:16 UTC 2012


Federico Simoncelli has posted comments on this change.

Change subject: added mtu support for network interface
......................................................................


Patch Set 6: (2 inline comments)

....................................................
File vdsm/configNetwork.py
Line 332:                     if line.startswith(entry + '=') ]
You may want to consider to:
- use strip() to remove any white character from the beginning/end of the line
- use split("=", 1) to split key/values (so you can avoid the startswith/[len(entry)+1:])
- use "with open(conffile)" to read the file

(Use the same suggestions for _updateConfigValue)

Line 548:                            gateway=gateway, **options)
Looks like addBridge/addVlan/addBonding/addNic are low level enough to assume that "mtu" value is correct. Therefore I would:
- get rid of all the "int(mtu)" in addBridge/addVlan/addBonding/addNic
- validate the mtu value only at the beginning of addNetwork (returning a descriptive error when needed)

--
To view, visit http://gerrit.ovirt.org/754
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I1d8f38627dd1a59830e426484228c1796081ad1b
Gerrit-PatchSet: 6
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Shahar Havivi <shavivi at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Mark Wu <wudxw at linux.vnet.ibm.com>
Gerrit-Reviewer: Peter V. Saveliev <peet at redhat.com>
Gerrit-Reviewer: Roy Golan <rgolan at redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi at redhat.com>
Gerrit-Reviewer: Shahar Havivi <shavivi at redhat.com>


More information about the vdsm-patches mailing list