Book Image

OpenFlow Cookbook

Book Image

OpenFlow Cookbook

Overview of this book

Table of Contents (17 chapters)
16
Index

Modifying a meter entry in a meter table

When the controller wants to modify a meter entry, the controller should send a meter modification message (OFPT_METER_MOD) with the command value set as OFPMC_MODIFY to the switch. This meter modification message contains the information required to identify and modify the meter.

Tip

The OFPT_METER_MOD message is used for all the meter operations such as adding a new meter, deleting an existing meter, and modifying a meter.

How to do it...

The message format that should be used by the controller to send OFPT_METER_MOD is defined in Adding a new group entry in a group table recipe of this chapter. Here, to modify a meter entry, the command field should be set as OFPMC_MODIFY.

The procedure to construct a group modification message for modifying a meter entry is similar to that of the one explained in the previous recipe.

How it works...

When the switch receives a meter modification message with the command OFPMC_MODIFY, the switch fetches a meter entry...