[ovs-discuss] Error writing million flows to OVS bridge

Farrukh Aftab Khan Farrukh.Khan at xflowresearch.com
Fri Dec 14 06:21:33 UTC 2012


Hello,

I was trying to push a million flows on br0 using the following loop in a
bash script:
for((i=0; i<1000; i++))
do
        src_port=$((65535 - $i))
        for((j=0; j<1000; j++))
        do
                dst_port=$((65535 - $j))
                ovs-ofctl add-flow br0
priority=65535,idle_timeout=0,in_port=ANY,dl_src=ANY,dl_dst=ANY,dl_type=0x0800,nw_src=ANY,nw_dst=ANY,nw_proto=17,tp_src=$src_port,tp_dst=$dst_port,actions=drop
        done
done

I am using OVS-1.7.1 on embedded Linux (kernel-2.6.32.27). I am running
this on OCTEON MIPS processor that has ten cores. After about 0.4 million
flows, I get the following error and the switch becomes non-responsive. The
same error comes repeatedly:

1970-01-01T00:28:45Z|00001|stream_unix|ERR|/home/farrukh/switch/bin/var/run/openvswitch/br0.mgmt:
connection failed (Connection refused)
ovs-ofctl: connecting to
unix:/home/farrukh/switch/bin/var/run/openvswitch/br0.mgmt (Connection
refused)

I also get this warning:
1970-01-01T00:28:15Z|00001|poll_loop|WARN|wakeup due to [POLLIN] on fd 6
(<->/home/farrukh/switch/bin/var/run/openvswitch/br0.mgmt) at
lib/stream-fd.c:143 (79% CPU usage)

~ # ovs-vswitchd --version
ovs-vswitchd (Open vSwitch) 1.7.1
Compiled Dec 13 2012 22:12:15
OpenFlow versions 0x1:0x1

~ # ovs-vsctl show
    Bridge "br0"
        Port "pci3"
            Interface "pci3"
        Port "xaui0"
            Interface "xaui0"
        Port "br0"
            Interface "br0"
                type: internal

~ # ovs-ofctl dump-tables br0
 1: table1  : wild=0x3fffff, max=1000000, active=0
               lookup=0, matched=0

>From what I see here, the table should be able to hold maximum of 1 million
flows.
Am I missing something here? Or have I overburdened the switch with flows
so it crashes?

Regards.

-Farrukh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://openvswitch.org/pipermail/ovs-discuss/attachments/20121214/f26d6671/attachment.html>


More information about the discuss mailing list