[ovs-git] [openvswitch/ovs] 367681: bridge: Fix high cpu utilization.

GitHub noreply at github.com
Thu Oct 9 16:52:40 UTC 2014


  Branch: refs/heads/branch-2.3
  Home:   https://github.com/openvswitch/ovs
  Commit: 367681a9213ab2d99177e222dad5ca69df1edf60
      https://github.com/openvswitch/ovs/commit/367681a9213ab2d99177e222dad5ca69df1edf60
  Author: Alex Wang <alexw at nicira.com>
  Date:   2014-10-09 (Thu, 09 Oct 2014)

  Changed paths:
    M tests/ovs-vswitchd.at
    M vswitchd/bridge.c

  Log Message:
  -----------
  bridge: Fix high cpu utilization.

When there are more than one ovs-vswitchd processes started,
only one process is enabled.  The disabled processes should
just sleep.  However, a bug in ovs makes the disabled processes
keep waking up on global connectivity sequence number which is
never sync'ed.  Consequently, those processes use 100% cpu.

This commit fixes the bug by always sync up the connectivity
sequence number for disabled processes.

Reported-by: Ben Pfaff <blp at nicira.com>
Signed-off-by: Alex Wang <alexw at nicira.com>
Acked-by: Joe Stringer <joestringer at nicira.com>


  Commit: b30f0a1fa182afd2a1d0b7c3d95399bc883808f7
      https://github.com/openvswitch/ovs/commit/b30f0a1fa182afd2a1d0b7c3d95399bc883808f7
  Author: YAMAMOTO Takashi <yamamoto at valinux.co.jp>
  Date:   2014-10-09 (Thu, 09 Oct 2014)

  Changed paths:
    M tests/ovs-vswitchd.at

  Log Message:
  -----------
  ovs-vswitchd.at: Fix "start additional ovs-vswitchd process" test

NetBSD implementation of wc command outputs extra whitespaces
like the following.  Tweak the test to success on such environments.

    % echo hoge|wc -l|hexdump -C
    00000000  20 20 20 20 20 20 20 31  0a                       |       1.|
    00000009
    %

The failing test was introduced by
commit 6bef3c7ca859f208239ca61ec3b25c09a3571553
("bridge: Fix high cpu utilization.")

Signed-off-by: YAMAMOTO Takashi <yamamoto at valinux.co.jp>
Acked-by: Joe Stringer <joestringer at nicira.com>


  Commit: 4c3925682f4bd7a98d0d967b6e692eb200ac08cf
      https://github.com/openvswitch/ovs/commit/4c3925682f4bd7a98d0d967b6e692eb200ac08cf
  Author: Alex Wang <alexw at nicira.com>
  Date:   2014-10-09 (Thu, 09 Oct 2014)

  Changed paths:
    M tests/ovs-vswitchd.at

  Log Message:
  -----------
  ovs-vswitchd.at: Add test for switch over to another ovs-vswitchd.

Test the switch over to inactive ovs-vswitchd process when user
kill the currently active ovs-vswitchd.

Signed-off-by: Alex Wang <alexw at nicira.com>
Acked-by: Joe Stringer <joestringer at nicira.com>


  Commit: 3e8ee3310d4c08d46ba11d456dd401b068106b3c
      https://github.com/openvswitch/ovs/commit/3e8ee3310d4c08d46ba11d456dd401b068106b3c
  Author: Gurucharan Shetty <gshetty at nicira.com>
  Date:   2014-10-09 (Thu, 09 Oct 2014)

  Changed paths:
    M tests/ovs-vswitchd.at

  Log Message:
  -----------
  ovs-vswitchd.at: Port tests to run successfully on Windows.

It is a little tricky to implement "$!" with unit tests on Windows.
This commit changes the tests so that it works both on Windows
and Linux.

Signed-off-by: Gurucharan Shetty <gshetty at nicira.com>
Acked-by: Alex Wang <alexw at nicira.com>


  Commit: e060b80dfb3f1a52d3c0b7399a2fcdba83b6f876
      https://github.com/openvswitch/ovs/commit/e060b80dfb3f1a52d3c0b7399a2fcdba83b6f876
  Author: Alex Wang <alexw at nicira.com>
  Date:   2014-10-09 (Thu, 09 Oct 2014)

  Changed paths:
    M tests/ovs-vswitchd.at
    M vswitchd/bridge.c

  Log Message:
  -----------
  ovs-vswitchd: Fix high cpu utilization when acquire idl lock fails.

When ovs-vswitchd fails to acquire the ovsdb idl lock (either due to
contention or due to invalid database path), ovs-vswitchd will spin
on the global connectivity sequence number and consume 100% cpu.
This is in that the local copy is different to the global sequence
number and never updated when ovsdb idl is not locked.

To fix this issue, this commit makes ovs-vswitchd not checking the
global connectivity sequence number in that situation.

Reported-by: Ben Pfaff <blp at nicira.com>
Signed-off-by: Alex Wang <alexw at nicira.com>
Acked-by: Ben Pfaff <blp at nicira.com>


Compare: https://github.com/openvswitch/ovs/compare/406e84289ee0...e060b80dfb3f


More information about the git mailing list