<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openvswitch.git, branch branch-1.2</title>
<subtitle>github.com: openvswitch/ovs.git
</subtitle>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/'/>
<entry>
<title>ovs-vswitchd: Call mlockall() from the daemon, not the parent or monitor.</title>
<updated>2012-07-02T17:18:13+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@nicira.com</email>
</author>
<published>2012-06-29T16:22:59+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=20831fc55121f727dd4d3b87434ad715e9eea8ee'/>
<id>20831fc55121f727dd4d3b87434ad715e9eea8ee</id>
<content type='text'>
mlockall(2) says:

       Memory  locks  are not inherited by a child created via fork(2) and are
       automatically removed  (unlocked)  during  an  execve(2)  or  when  the
       process terminates.

which means that --mlockall was ineffective in combination with --detach
or --monitor or both.  Both are used in the most common production
configuration of Open vSwitch, so this means that --mlockall has never been
effective in production.

Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
mlockall(2) says:

       Memory  locks  are not inherited by a child created via fork(2) and are
       automatically removed  (unlocked)  during  an  execve(2)  or  when  the
       process terminates.

which means that --mlockall was ineffective in combination with --detach
or --monitor or both.  Both are used in the most common production
configuration of Open vSwitch, so this means that --mlockall has never been
effective in production.

Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lib: Do not assume sig_atomic_t is int.</title>
<updated>2012-06-26T16:35:01+00:00</updated>
<author>
<name>Ed Maste</name>
<email>emaste@freebsd.org</email>
</author>
<published>2012-06-26T14:43:54+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=03dbf1330e335e963450032320e43bda03447065'/>
<id>03dbf1330e335e963450032320e43bda03447065</id>
<content type='text'>
On FreeBSD sig_atomic_t is long, which causes the comparison in
fatal_signal_run to be true when no signal has been reported.

Signed-off-by: Ed Maste &lt;emaste@freebsd.org&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On FreeBSD sig_atomic_t is long, which causes the comparison in
fatal_signal_run to be true when no signal has been reported.

Signed-off-by: Ed Maste &lt;emaste@freebsd.org&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ofproto: Fix use-after-free error when ports disappear.</title>
<updated>2012-04-23T21:06:11+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@nicira.com</email>
</author>
<published>2012-04-23T16:16:18+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=7d09d61fac2c19d23b7b3cee501a4404220c9f46'/>
<id>7d09d61fac2c19d23b7b3cee501a4404220c9f46</id>
<content type='text'>
update_port() can delete the port for which it is called, if the underlying
network device has been destroyed, so HMAP_FOR_EACH is unsafe in
ofproto_run().

Less obviously, update_port() can delete unrelated ports.  For example,
suppose that initially device A is port 1 and device B is port 2.  If
update_port("A") runs just after this, then it will ofport_remove() both
ports, then ofport_install() A as the new port 2.

So this commit first assembles a list of ports to update, then updates them
in a separate loop.

Without this commit, running "ovs-dpctl del-dp" while ovs-vswitchd is
running consistently causes a crash for me within a few seconds.

Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
update_port() can delete the port for which it is called, if the underlying
network device has been destroyed, so HMAP_FOR_EACH is unsafe in
ofproto_run().

Less obviously, update_port() can delete unrelated ports.  For example,
suppose that initially device A is port 1 and device B is port 2.  If
update_port("A") runs just after this, then it will ofport_remove() both
ports, then ofport_install() A as the new port 2.

So this commit first assembles a list of ports to update, then updates them
in a separate loop.

Without this commit, running "ovs-dpctl del-dp" while ovs-vswitchd is
running consistently causes a crash for me within a few seconds.

Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>debian: Fix log rotation.</title>
<updated>2012-03-22T17:35:05+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@nicira.com</email>
</author>
<published>2012-03-22T17:20:44+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=c38e95a3368d68e66387796c26708516f69bcc94'/>
<id>c38e95a3368d68e66387796c26708516f69bcc94</id>
<content type='text'>
Commit 24e81092a1 (debian: Bring Debian packaging in-line with new file
locations) introduced an ambiguous "--t" option invoking ovs-appctl, so
ovs-vswitchd and ovsdb-server were not reopening their log files following
log rotation.  This fixes the problem by correct the option name.

Reported-by: Paul Ingram &lt;paul@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 24e81092a1 (debian: Bring Debian packaging in-line with new file
locations) introduced an ambiguous "--t" option invoking ovs-appctl, so
ovs-vswitchd and ovsdb-server were not reopening their log files following
log rotation.  This fixes the problem by correct the option name.

Reported-by: Paul Ingram &lt;paul@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>netdev-linux: Fix use-after-free when netdev_dump_queues() deletes queues.</title>
<updated>2012-03-19T20:53:11+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@nicira.com</email>
</author>
<published>2012-03-19T20:47:50+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=1ed3447a09b46de45a87b37a989b11e1de3bfc00'/>
<id>1ed3447a09b46de45a87b37a989b11e1de3bfc00</id>
<content type='text'>
iface_configure_qos() passes a callback to netdev_dump_queues() that can
delete queues.  The netdev-linux implementation of this function was
unprepared for the callback to delete queues, so this could cause a
use-after-free.  This fixes the problem in netdev_linux_dump_queues() and
documents that netdev_dump_queues() implementations must support deletions
in the callback.

Found by valgrind:

==1593== Invalid read of size 8
==1593==    at 0x4A8C43: netdev_linux_dump_queues (hmap.h:326)
==1593==    by 0x4305F7: bridge_reconfigure (bridge.c:3084)
==1593==    by 0x431384: bridge_run (bridge.c:1892)
==1593==    by 0x432749: main (ovs-vswitchd.c:96)
==1593==  Address 0x632e078 is 8 bytes inside a block of size 32 free'd
==1593==    at 0x4C240FD: free (vg_replace_malloc.c:366)
==1593==    by 0x4A4D74: hfsc_class_delete (netdev-linux.c:3250)
==1593==    by 0x42AA59: iface_delete_queues (bridge.c:3055)
==1593==    by 0x4A8C8C: netdev_linux_dump_queues (netdev-linux.c:1881)
==1593==    by 0x4305F7: bridge_reconfigure (bridge.c:3084)
==1593==    by 0x431384: bridge_run (bridge.c:1892)

Bug #10164.
Reported-by: Ram Jothikumar &lt;ram@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
iface_configure_qos() passes a callback to netdev_dump_queues() that can
delete queues.  The netdev-linux implementation of this function was
unprepared for the callback to delete queues, so this could cause a
use-after-free.  This fixes the problem in netdev_linux_dump_queues() and
documents that netdev_dump_queues() implementations must support deletions
in the callback.

Found by valgrind:

==1593== Invalid read of size 8
==1593==    at 0x4A8C43: netdev_linux_dump_queues (hmap.h:326)
==1593==    by 0x4305F7: bridge_reconfigure (bridge.c:3084)
==1593==    by 0x431384: bridge_run (bridge.c:1892)
==1593==    by 0x432749: main (ovs-vswitchd.c:96)
==1593==  Address 0x632e078 is 8 bytes inside a block of size 32 free'd
==1593==    at 0x4C240FD: free (vg_replace_malloc.c:366)
==1593==    by 0x4A4D74: hfsc_class_delete (netdev-linux.c:3250)
==1593==    by 0x42AA59: iface_delete_queues (bridge.c:3055)
==1593==    by 0x4A8C8C: netdev_linux_dump_queues (netdev-linux.c:1881)
==1593==    by 0x4305F7: bridge_reconfigure (bridge.c:3084)
==1593==    by 0x431384: bridge_run (bridge.c:1892)

Bug #10164.
Reported-by: Ram Jothikumar &lt;ram@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tests: Prefer development Python files over installed ones.</title>
<updated>2012-03-09T22:08:29+00:00</updated>
<author>
<name>Ethan Jackson</name>
<email>ethan@nicira.com</email>
</author>
<published>2012-03-02T00:21:55+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=edcb6e25301694e9310210f126da80781f792132'/>
<id>edcb6e25301694e9310210f126da80781f792132</id>
<content type='text'>
A developer may have Open vSwitch installed, in which case many of
the Python files which are tested will be in both the development
tree and the system Python library.  When running unit tests, we
want to test the development tree, so it's better to prefer
importing those files.

Signed-off-by: Ethan Jackson &lt;ethan@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A developer may have Open vSwitch installed, in which case many of
the Python files which are tested will be in both the development
tree and the system Python library.  When running unit tests, we
want to test the development tree, so it's better to prefer
importing those files.

Signed-off-by: Ethan Jackson &lt;ethan@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bond: Incorrectly reported an error in appctl.</title>
<updated>2012-03-08T22:36:33+00:00</updated>
<author>
<name>Ethan Jackson</name>
<email>ethan@nicira.com</email>
</author>
<published>2012-02-21T05:57:20+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=23d117bbf1c8f477b39119a9fa3e6d85b67c5aa3'/>
<id>23d117bbf1c8f477b39119a9fa3e6d85b67c5aa3</id>
<content type='text'>
The bond/enable-slave and bond/disable-slave ovs-appctl commands
incorrectly reported the 501 error code upon success.

Signed-off-by: Ethan Jackson &lt;ethan@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The bond/enable-slave and bond/disable-slave ovs-appctl commands
incorrectly reported the 501 error code upon success.

Signed-off-by: Ethan Jackson &lt;ethan@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>socket-util: Unlink Unix domain sockets that bind but fail to connect.</title>
<updated>2012-03-08T00:40:25+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@nicira.com</email>
</author>
<published>2012-02-27T18:58:45+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=136b697c4a1dedcd82128662bac28fbdfbc8d7a8'/>
<id>136b697c4a1dedcd82128662bac28fbdfbc8d7a8</id>
<content type='text'>
The error handling path here failed to clean up bound sockets, by removing
them.  This fixes the problem.

It was easy to observe this bug by running "ovs-vsctl" without
"ovsdb-server" running.

Bug #9811.
Bug #9769.
Reported-by: Michael &lt;mhu@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The error handling path here failed to clean up bound sockets, by removing
them.  This fixes the problem.

It was easy to observe this bug by running "ovs-vsctl" without
"ovsdb-server" running.

Bug #9811.
Bug #9769.
Reported-by: Michael &lt;mhu@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bridge: Remove unwanted ports at time of ofproto creation.</title>
<updated>2012-03-05T21:17:03+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@nicira.com</email>
</author>
<published>2012-03-02T21:26:35+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=47dbce939838ba73c1bb9dd459a19045d7ff392e'/>
<id>47dbce939838ba73c1bb9dd459a19045d7ff392e</id>
<content type='text'>
The reconfiguration code only deleted unwanted ports for bridges that had
been created in previous (re)configurations.  In fact, we should run this
step even for bridges that are newly added, e.g. to delete ports that
were added by a previous run of ovs-vswitchd and deleted from the database
between runs.

Before this commit, the following left "int" in datapath br0.  After this
commit, "int" is properly deleted:

1. With ovs-vswitchd running:
      # ovs-vsctl add-br br0
      # ovs-vsctl add-port br0 int -- set interface int type=internal
2. Kill ovs-vswitchd, then:
      # ovs-vsctl --no-wait -- del-port br0 int
3. Restart ovs-vswitchd.

Bug #9957.
Reported-by: Hiroshi Tanaka &lt;htanaka@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The reconfiguration code only deleted unwanted ports for bridges that had
been created in previous (re)configurations.  In fact, we should run this
step even for bridges that are newly added, e.g. to delete ports that
were added by a previous run of ovs-vswitchd and deleted from the database
between runs.

Before this commit, the following left "int" in datapath br0.  After this
commit, "int" is properly deleted:

1. With ovs-vswitchd running:
      # ovs-vsctl add-br br0
      # ovs-vsctl add-port br0 int -- set interface int type=internal
2. Kill ovs-vswitchd, then:
      # ovs-vsctl --no-wait -- del-port br0 int
3. Restart ovs-vswitchd.

Bug #9957.
Reported-by: Hiroshi Tanaka &lt;htanaka@nicira.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>INSTALL.Linux: minor typo</title>
<updated>2012-03-02T18:23:23+00:00</updated>
<author>
<name>Chris Wright</name>
<email>chrisw@sous-sol.org</email>
</author>
<published>2012-03-02T05:14:56+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/openvswitch.git/commit/?id=5ec9b71999cf17f8e4eea948bf60a419270242c4'/>
<id>5ec9b71999cf17f8e4eea948bf60a419270242c4</id>
<content type='text'>
s/ovsdmonitor/ovsdbmonitor/

Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
s/ovsdmonitor/ovsdbmonitor/

Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
Signed-off-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
