[pox-dev] Forwarding L2 Learning Example Behavior
Murphy McCauley
murphy.mccauley at gmail.com
Thu Sep 6 21:40:42 PDT 2012
On Sep 4, 2012, at 7:20 PM, William Emmanuel Yu wrote:
> I am new to openflow and pox and have gone through the openflow tutorial
> that uses pox. I would like some clarification on the behavior of
> "installing a flow". It is my assumption that if the flow is present in
> the switch then that switch won't do a packet_in anymore to the openflow
> controller. However, the log below shows that even if the flow already
> is in the switch it still triggered a packet_in. Is that the intended
> behavior for ovsk?
>
> The output:
> POX> INFO:openflow.of_01:[Con 1/1] Connected to 00-00-00-00-00-01
> DEBUG:forwarding.l2_learning:Connection [Con 1/1]
> DEBUG:forwarding.l2_learning:installing flow for 00:00:00:00:00:03.2 ->
> 00:00:00:00:00:02.1
> DEBUG:forwarding.l2_learning:installing flow for 00:00:00:00:00:02.1 ->
> 00:00:00:00:00:03.2
> DEBUG:forwarding.l2_learning:installing flow for 00:00:00:00:00:03.2 ->
> 00:00:00:00:00:02.1
l2_learning installs exact matches -- not just on MAC address, but on IP addresses, TCP ports, etc. However, the log messages only reflect the MAC addresses. Thus, you may see log entries with duplicate MAC addresses, but other fields will be different. Also, these entries eventually expire. This is easy to see with the upcoming GUI... it might also be easy to see with the current GUI, but I am not sure (you could try it out).
You could certainly write a switch that worked a different way (e.g., installed rules based only on MAC addresses), which would behave differently.
> Finally, what is the best way to implement a traffic monitoring solution
> using openflow if all packets do not generate a packet_in as intended?
Depending on exactly what you want, OpenFlow might or might not be a good tool for the job.
If OpenFlow is workable, it's probably because you can use the packet or byte counter statistics for table entries -- install flow entries, and query them periodically to see the counters.
Hope that helps.
-- Murphy
More information about the pox-dev
mailing list