Book Image

OpenFlow Cookbook

Book Image

OpenFlow Cookbook

Overview of this book

Table of Contents (17 chapters)
16
Index

Getting statistics of flow table using multipart messages

When the controller wants to get statistics of a flow table, it should send OFPMP_TABLE multipart message (ofp_multipart_request) to switch.

How to do it...

The message format that should be used by controller for sending the multipart request message is defined in the Introduction section of this Chapter.

For getting the statistics of a flow entry, the controller should set the type field as OFPMP_TABLE.

The body field should be left empty.

After sending the multipart request message, the controller should wait for the reply message from switch. If the size of the reply message exceeds the maximum limit of OpenFlow message (which is 64KB) then the switch sends this message as a sequence of multiple reply messages with flag field in multipart message header set as OFPMPF_REPLY_MORE. If the controller receives the reply message with this flag set, then the controller should buffer the sequence of multipart messages till it receives the...