Closed Allamuth closed 2 years ago
The best reference for this is probably: http://www.openvswitch.org//support/dist-docs/ovs-fields.7.txt
Open vSwitch called this match "NXM_OF_ETH_TYPE". The NXM because it's using the Nicira extended match. The OF because it's also defined as part of OpenFlow (the type of match itself is not really a Nicira extension). IIRC, you can use that name, but POX also lets you drop the prefixes, so I think you can just use ".eth_type".
Thank you for your fast answer. After changing my code according the provided reference:
msg = nx.nx_flow_mod()
msg.priority = 35000
msg.match.eth_type = 0x86dd
msg.match.ipv6_dst = 'fd97:a9a1:980f::d4e' # or 'fd97:a9a1:980f::d4e/128'
msg.match.ip_proto = 17
msg.match.udp_dst = 90
event.connection.send(msg)
This leads to the following traceback:
Traceback (most recent call last):
File "/home/mininet/pox/pox/lib/revent/revent.py", line 242, in raiseEventNoErrors
return self.raiseEvent(event, *args, **kw)
File "/home/mininet/pox/pox/lib/revent/revent.py", line 295, in raiseEvent
rv = event._invoke(handler, *args, **kw)
File "/home/mininet/pox/pox/lib/revent/revent.py", line 168, in _invoke
return handler(self, *args, **kw)
File "/home/mininet/pox/pox/forwarding/l2_nx_self_learning_filtering.py", line 77, in _handle_ConnectionUp
msg.match.ipv6_dst = 'fd97:a9a1:980f::d4e'
File "/home/mininet/pox/pox/openflow/nicira.py", line 2760, in __setattr__
entry.value = value
File "/home/mininet/pox/pox/openflow/nicira.py", line 1837, in value
self.mask = mask
File "/home/mininet/pox/pox/openflow/nicira.py", line 2011, in mask
self._mask = self._pack_mask(value)
File "/home/mininet/pox/pox/openflow/nicira.py", line 1853, in _pack_mask
return IPAddr6.from_num(n).raw
AttributeError: 'bytes' object has no attribute 'raw'
What is the format needed for specifying IPv6 Addresses as match? As this seems to be causing the error.
Please file this as a new issue (and include the version of POX that you're using).
Hello,
I'm currently trying to install a match using nx_flow_mod. I added the the following code snippet to
_handle_ConnectionUp
inl2_nx_self_learning
for testing:When running
./pox.py log.level --DEBUG openflow.nicira forwarding.l2_nx_self_learning
I get the following Traceback:I understand, that there are different names for attribute when using
nx_match
in contrast toofp_match
, but I fail to find the correct naming scheme for 'dl_type'. Could someone please explain briefly, if this is an error on my end and how to fix it, or if it is an issue with pox.