Book Image

OpenFlow Cookbook

Book Image

OpenFlow Cookbook

Overview of this book

Table of Contents (17 chapters)
16
Index

Deleting a meter entry

When the controller wants to delete a meter entry, it should send a meter modification message (OFPT_METER_MOD) to the switch. This meter modification message contains the information required to delete the meter which includes the meter identifier, bands and so on.

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 delete a meter entry, the command field should be set OFPMC_DELETE.

The procedure to construct a meter modification message for deleting a meter entry is similar to that of the one explained in the previous recipe. However, while deleting an entry, the controller need not set the bands in a modification message.

Tip

If the controller wants to delete all the entries from the meter table...