[ovs-dev] [PATCH v6 2/2] dpctl: dpif: allow viewing and configuring dp cache sizes

Eelco Chaudron echaudro at redhat.com
Fri Nov 5 09:22:06 UTC 2021



On 4 Nov 2021, at 16:21, Ilya Maximets wrote:

> Hi, Eelco.  Thanks for the patch!
>
> I'd like to test it a bit more on my setup before applying, but the
> code looks mostly OK to me.
>
> See some nits inline.
>
> Bets regards, Ilya Maximets.
>
> On 9/6/21 10:53, Eelco Chaudron wrote:
>> This patch adds a general way of viewing/configuring datapath
>> cache sizes. With an implementation for the netlink interface.
>>
>> The ovs-dpctl/ovs-appctl show commands will display the
>> current cache sizes configured:
>>
>> ovs-dpctl show
>> system at ovs-system:
>>   lookups: hit:25 missed:63 lost:0
>>   flows: 0
>>   masks: hit:282 total:0 hit/pkt:3.20
>>   cache: hit:4 hit rate:4.54%
>>   caches:
>>     masks-cache: size: 256
>
> I'd remove the extra space here, i.e. 'size:256' instead of 'size: 256',
> to make it look similar to other stats in the output.
>
> What do you think?  I can change that before applying the patch.

Yes, you are right. Please make the change when applying.

>>   port 0: ovs-system (internal)
>>   port 1: br-int (internal)
>>   port 2: genev_sys_6081 (geneve: packet_type=ptap)
>>   port 3: br-ex (internal)
>>   port 4: eth2
>>   port 5: sw0p1 (internal)
>>   port 6: sw0p3 (internal)
>>
>> A specific cache can be configured as follows:
>>
>> ovs-appctl dpctl/cache-set-size DP CACHE SIZE
>> ovs-dpctl cache-set-size DP CACHE SIZE
>
> New commands needs a mention in the NEWS file, but I can add this
> on commit too.
Thanks!

//Eelco

>>
>> For example to disable the cache do:
>>
>> $ ovs-dpctl cache-set-size system at ovs-system masks-cache 0
>> Setting cache size successful, new size 0.
>>
>> Signed-off-by: Eelco Chaudron <echaudro at redhat.com>
>> Acked-by: Paolo Valerio <pvalerio at redhat.com>
>> Acked-by: Flavio Leitner <fbl at sysclose.org>



More information about the dev mailing list