pstream-unix: Increase listen count to 64 in punix_open().
authorLilijun <jerry.lilijun@huawei.com>
Tue, 30 Sep 2014 08:55:25 +0000 (16:55 +0800)
committerBen Pfaff <blp@nicira.com>
Tue, 30 Sep 2014 15:39:39 +0000 (08:39 -0700)
In my test with openstack setup, ovs-ofctl executes failed when there are
many flow rules to be added by multiple threads.
The error like this:
ovs-ofctl: /var/run/openvswitch/br1.mgmt: failed to open socket (Protocol
error)

In the function listen(fd, 10) in punix_open(), the number 10 should be
modified to more bigger, such as 64 maybe a proper value.

Signed-off-by: Lilijun <jerry.lilijun@huawei.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
AUTHORS
lib/stream-unix.c

diff --git a/AUTHORS b/AUTHORS
index 3d19f27..518c10a 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -86,6 +86,7 @@ Krishna Kondaka         kkondaka@vmware.com
 Kyle Mestery            kmestery@cisco.com
 Lars Kellogg-Stedman    lars@redhat.com
 Leo Alterman            lalterman@nicira.com
+Lilijun                 jerry.lilijun@huawei.com
 Linda Sun               lsun@vmware.com
 Lior Neudorfer          lior@guardicore.com
 Lorand Jakab            lojakab@cisco.com
index b3d70b6..ab5252b 100644 (file)
@@ -93,7 +93,7 @@ punix_open(const char *name OVS_UNUSED, char *suffix,
         return errno;
     }
 
-    if (listen(fd, 10) < 0) {
+    if (listen(fd, 64) < 0) {
         error = errno;
         VLOG_ERR("%s: listen: %s", name, ovs_strerror(error));
         close(fd);