Change in vdsm[master]: Add vlanid to vlans information

asegurap at redhat.com asegurap at redhat.com
Wed Aug 14 22:42:00 UTC 2013


Antoni Segura Puimedon has posted comments on this change.

Change subject: Add vlanid to vlans information
......................................................................


Patch Set 2: Code-Review-1

(2 comments)

Thanks a lot for the patch Amador.

....................................................
File lib/vdsm/netinfo.py
Line 491: 
Line 492: 
Line 493: def _vlaninfo(vlan):
Line 494:     info = _devinfo(vlan)
Line 495:     info.update({'iface': vlan.split('.')[0], 'vlanid': getVlanID(vlan)})
the iface should be retrieved using getVlanDevice, which could use a similar rewrite like the one you did to getVlanID.
Line 496:     return (vlan, info)
Line 497: 
Line 498: 
Line 499: def _devinfo(dev):


Line 553:     cmd = [constants.EXT_IP, '-d', 'link', 'show', 'dev', vlan]
Line 554:     rc, out, err = utils.execCmd(cmd)
Line 555: 
Line 556:     if rc != 0:
Line 557:         raise Exception
I'd prefer the exection to have err as a message.
Line 558: 
Line 559:     for item in out:
Line 560:         if "vlan id" in item:
Line 561:             vlanId = item.split()[2]


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

Gerrit-MessageType: comment
Gerrit-Change-Id: If94dfd94c99272f6cb7dbc3d57cca78b05712119
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Amador Pahim <apahim at redhat.com>
Gerrit-Reviewer: Amador Pahim <apahim at redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegurap at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Giuseppe Vallarelli <gvallare at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list