Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if datapath.id==1:
- out_port=2
- actions=[parser.OFPActionOutput(out_port)]
- match=parser.OFPMatch(eth_type=0x0800, ipv4_src="10.0.0.1", ipv4_dst="10.0.0.2")
- self.add_flow(datapath, match, actions, DEFAULT_PRIORITY, 1000, 1000)
- out_port =1
- actions = [parser.OFPActionOutput(out_port)]
- match=parser.OFPMatch(eth_type=0x0800, ipv4_src="10.0.0.2", ipv4_dst="10.0.0.1")
- self.add_flow(datapath, match, actions, DEFAULT_PRIORITY, 1000, 1000)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement