Created
February 21, 2014 19:09
-
-
Save mavenugo/9141111 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
497 if action == 'add': | |
498 actions = ('move:NXM_OF_ETH_SRC[]->NXM_OF_ETH_DST[],' | |
499 'mod_dl_src:%(mac)s,' | |
500 'load:0x2->NXM_OF_ARP_OP[],' | |
501 'move:NXM_NX_ARP_SHA[]->NXM_NX_ARP_THA[],' | |
502 'move:NXM_OF_ARP_SPA[]->NXM_OF_ARP_TPA[],' | |
503 'load:%(mac)#x->NXM_NX_ARP_SHA[],' | |
504 'load:%(ip)#x->NXM_OF_ARP_SPA[],' | |
505 'in_port' % {'mac': mac, 'ip': ip}) | |
506 self.tun_br.add_flow(table=constants.ARP_RESPONDER, | |
507 priority=1, | |
508 proto='arp', | |
509 dl_vlan=lvid, | |
510 nw_dst='%s' % ip, | |
511 actions=actions) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment