[ovs-discuss] Meter IDs and meter cleanup on disconnect
Ben Pfaff
blp at nicira.com
Mon Sep 22 17:07:30 UTC 2014
On Sun, Sep 21, 2014 at 05:33:36AM +0000, Gur Stavi wrote:
> I have 2 questions about meters:
>
> If OVS loses connection to controller it delete active flows
No, it doesn't.
> but does not delete active meters. Shouldn't meters be deleted as
> well.
How are you adding meters? The FAQ says:
Q: Does Open vSwitch support OpenFlow meters?
A: Since version 2.0, Open vSwitch has OpenFlow protocol support for
OpenFlow meters. There is no implementation of meters in the Open
vSwitch software switch (neither the kernel-based nor userspace
switches).
> Meters are stored in an array in ofproto where meter_id is used as an index into the array.
> The datapath need to pre-declare the array size using max_meters during a call to meter_get_features.
> This puts a hard limit on the range of Meter IDs 0-max_meters.
> It may be very convenient to the controller to have freedom in the selection of meter_id 32 bits in order to easily associate flows to meters.
This is not an Open vSwitch restriction. It comes straight from the
OpenFlow specification: "Meters are defined starting with meter_id=1
up to the maximum number of meters that the switch can support."
> For example: if the bridge states that max_meters=4 the controller may want to select meter-ids as a function of vlan: 1000, 1200, 1560, 3420.
> Is it possible to change meters in ofproto from an array into hash?
Only if you change OpenFlow first.
More information about the discuss
mailing list