Change in vdsm[master]: WIP: Multiple Gateways[3/2]: Re-did comms between dhclient a...

amuller at redhat.com amuller at redhat.com
Sun Jul 7 11:36:15 UTC 2013


Assaf Muller has posted comments on this change.

Change subject: WIP: Multiple Gateways[3/2]: Re-did comms between dhclient and vdsm
......................................................................


Patch Set 2: (4 inline comments)

Thanks Toni, good comments. The next patch set will address your review.

....................................................
File vdsm/sourceRoute.sh
Line 1: #!/bin/bash
Line 2: 
Line 3: sourceRoute_config() {
Line 4:     echo "configure" $new_ip_address $new_subnet_mask $new_routers \
Line 5:         $interface > /var/run/vdsm/sourceRoutes/$interface
Done
Line 6: }
Line 7: 
Line 8: sourceRoute_restore() {
Line 9:     echo "remove" $interface > /var/run/vdsm/sourceRoutes/$interface


....................................................
File vdsm/sourceRouteThread.py
Line 6: from netconf.iproute2 import Iproute2
Line 7: from sourceRoute import DynamicSourceRoute
Line 8: 
Line 9: 
Line 10: SOURCE_ROUTES_FOLDER = os.path.join(os.sep, 'var', 'run', 'vdsm',
Done
Line 11:                                     'sourceRoutes', '')
Line 12: configurator = Iproute2()
Line 13: 
Line 14: 


Line 11:                                     'sourceRoutes', '')
Line 12: configurator = Iproute2()
Line 13: 
Line 14: 
Line 15: class dhClientEventHandler(pyinotify.ProcessEvent):
Done
Line 16:     def process_IN_CREATE(self, event):
Line 17:         with open(event.pathname, 'r') as sourceRouteFile:
Line 18:             sourceRouteContents = sourceRouteFile.read().split()
Line 19:             action = sourceRouteContents[0]


Line 19:             action = sourceRouteContents[0]
Line 20:             device = sourceRouteContents[-1]
Line 21:             sourceRoute = DynamicSourceRoute(device, configurator)
Line 22: 
Line 23:             if action == 'configure':
Done
Line 24:                 ip = sourceRouteContents[1]
Line 25:                 mask = sourceRouteContents[2]
Line 26:                 gateway = sourceRouteContents[3]
Line 27:                 sourceRoute.configure(ip, mask, gateway)


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

Gerrit-MessageType: comment
Gerrit-Change-Id: Ib7a47a680bfbfe285f708290de97e8f08714695a
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller <amuller at redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegurap at redhat.com>
Gerrit-Reviewer: Assaf Muller <amuller 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


More information about the vdsm-patches mailing list