<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
What's more, the steps I followed is from the openvswitch FAQ document in&nbsp;<a href="http://docs.openvswitch.org/en/latest/faq/issues/" id="LPlnk120335">http://docs.openvswitch.org/en/latest/faq/issues/</a></div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
But even follow these steps, every time I need to reconfigure the bridge interface such as br0's ip address etc ...</div>
<div id="LPBorder_GTaHR0cDovL2RvY3Mub3BlbnZzd2l0Y2gub3JnL2VuL2xhdGVzdC9mYXEvaXNzdWVzLw.." class="LPBorder369706" contenteditable="false" style="width: 100%; margin-top: 16px; margin-bottom: 16px; position: relative; max-width: 800px; min-width: 424px;">
<table id="LPContainer369706" role="presentation" style="padding: 12px 36px 12px 12px; width: 100%; border-width: 1px; border-style: solid; border-color: rgb(200, 200, 200); border-radius: 2px;">
<tbody>
<tr valign="top" style="border-spacing: 0px;">
<td style="width: 100%;">
<div id="LPTitle369706" style="font-size: 21px; font-weight: 300; margin-right: 8px; font-family: wf_segoe-ui_light, &quot;Segoe UI Light&quot;, &quot;Segoe WP Light&quot;, &quot;Segoe UI&quot;, &quot;Segoe WP&quot;, Tahoma, Arial, sans-serif; margin-bottom: 12px;">
<a target="_blank" id="LPUrlAnchor369706" href="http://docs.openvswitch.org/en/latest/faq/issues/" style="text-decoration: none; color: var(--themePrimary);">Common Configuration Issues - Open vSwitch Documentation</a></div>
<div id="LPDescription369706" style="font-size: 14px; max-height: 100px; color: rgb(102, 102, 102); font-family: wf_segoe-ui_normal, &quot;Segoe UI&quot;, &quot;Segoe WP&quot;, Tahoma, Arial, sans-serif; margin-bottom: 12px; margin-right: 8px; overflow: hidden;">
A: More than likely, you’ve looped your network. Probably, eth0 and eth1 are connected to the same physical Ethernet switch. This yields a scenario where OVS receives a broadcast packet on eth0 and sends it out on eth1, then the physical switch connected to
 eth1 sends the packet back on eth0, and so on forever.</div>
<div id="LPMetadata369706" style="font-size: 14px; font-weight: 400; color: rgb(166, 166, 166); font-family: wf_segoe-ui_normal, &quot;Segoe UI&quot;, &quot;Segoe WP&quot;, Tahoma, Arial, sans-serif;">
docs.openvswitch.org</div>
</td>
</tr>
</tbody>
</table>
</div>
<br>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<p style="font-family: Arial, Helvetica, sans-serif; font-size: 14px">Q: I can’t unload the openvswitch kernel module. Why?</p>
<blockquote style="font-family: Arial, Helvetica, sans-serif; font-size: 14px">
<div style="vertical-align: top">
<p>A: The userspace might still hold the reference count. So<span>&nbsp;</span><code style="font-weight: 700"><span>rmmod</span><span>&nbsp;</span><span>openvswitch</span></code><span>&nbsp;</span>does not work, for example:</p>
<div style="vertical-align: top">
<div style="vertical-align: top; border: 1px solid rgb(234, 234, 234); border-radius: 4px; margin: 25px 0px; overflow: auto; padding: 10px 20px; background: rgb(240, 240, 240)">
<pre style="overflow: auto; margin: 0px"><span></span>$ lsmod | grep openvswitch
openvswitch       155648 4
nf_conncount      24576  1 openvswitch
</pre>
</div>
</div>
<p>Use the command below to drop the refcnt:</p>
<div style="vertical-align: top">
<div style="vertical-align: top; border: 1px solid rgb(234, 234, 234); border-radius: 4px; margin: 25px 0px; overflow: auto; padding: 10px 20px; background: rgb(240, 240, 240)">
<pre style="overflow: auto; margin: 0px"><span></span>$ ovs-dpctl del-dp system@ovs-system
$ rmmod openvswitch</pre>
</div>
</div>
</div>
</blockquote>
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div id="signature">
<p>发送自 <a href="http://aka.ms/weboutlook">Outlook</a><br>
</p>
<div>
<div id="appendonsend"></div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>发件人:</b> ovs-discuss-bounces@openvswitch.org &lt;ovs-discuss-bounces@openvswitch.org&gt; 代表 pei Jikui &lt;jkpei@hotmail.com&gt;<br>
<b>发送时间:</b> 2019年3月20日 15:02<br>
<b>收件人:</b> ovs-discuss@openvswitch.org<br>
<b>主题:</b> [ovs-discuss] replace the openvswitch.ko without losing the bridge interface's configuration</font>
<div>&nbsp;</div>
</div>
<div dir="ltr">
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
When I replace the openvswitch.ko with a new modified one, the configuration on the bridge such as br0 is lost.<span style="">&nbsp;
</span>I need to reconfigure its ip address and bring it up again manually. </p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
Is there any alternative that we could replace the openvswitch.ko without losing the bridge interfaces’ configuration?</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
The steps I used to replace the openvswitch on the centos.</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin:0cm 0cm 0.0001pt; font-size:12pt; font-family:Calibri,sans-serif; margin-right:0cm; margin-left:0cm; font-family:&quot;Times New Roman&quot;,serif">
</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin:0cm 0cm 0.0001pt 36pt; font-family:Calibri,sans-serif; text-indent:-18.0pt">
<span style=""><span style="">1)<span style="font:7.0pt &quot;Times New Roman&quot;">&nbsp;&nbsp;&nbsp; </span>
</span></span>Compile the openvswitch</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin-top:0cm; margin-right:0cm; margin-bottom:0cm; margin-left:36.0pt; margin-bottom:.0001pt">
<span style="font-size:10.0pt; font-family:Consolas; color:#333333; background:#F7F7F7">make -j `nproc`</span><span style="font-size:10.0pt; font-family:Consolas; color:#333333"></span></p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin-top:0cm; margin-right:0cm; margin-bottom:0cm; margin-left:36.0pt; margin-bottom:.0001pt">
<span style="font-size:10.0pt; font-family:Consolas; color:#333333; background:#F7F7F7">make install</span><span style="font-size:10.0pt; font-family:Consolas; color:#333333"></span></p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin:0cm 0cm 0.0001pt 36pt; font-family:Calibri,sans-serif; text-indent:-18.0pt">
<span style=""><span style="">2)<span style="font:7.0pt &quot;Times New Roman&quot;">&nbsp;&nbsp;&nbsp; </span>
</span></span>Replace the openvswitch.ko</p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin-top:0cm; margin-right:0cm; margin-bottom:0cm; margin-left:36.0pt; margin-bottom:.0001pt">
<span style="font-size:10.5pt; font-family:&quot;Arial&quot;,sans-serif; color:black">ovs-dpctl del-dp system@ovs-system</span></p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin-top:0cm; margin-right:0cm; margin-bottom:0cm; margin-left:36.0pt; margin-bottom:.0001pt">
<span style="font-size:10.5pt; font-family:&quot;Arial&quot;,sans-serif; color:black">rmmod openvswitch</span></p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin-top:0cm; margin-right:0cm; margin-bottom:0cm; margin-left:36.0pt; margin-bottom:.0001pt">
<span style="font-size:11.0pt; font-family:&quot;Calibri&quot;,sans-serif">insmod ./datapath/linux/openvswitch.ko</span></p>
<p style="margin-top: 0px; margin-bottom: 0px;margin-right:0cm; margin-left:0cm; font-size:12pt; font-family:&quot;Times New Roman&quot;,serif; margin-top:0cm; margin-right:0cm; margin-bottom:0cm; margin-left:36.0pt; margin-bottom:.0001pt">
<span style="font-size:11.0pt; font-family:&quot;Calibri&quot;,sans-serif">ovs-ctl restart</span></p>
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div id="x_signature">
<p style="margin-top: 0px; margin-bottom: 0px;">Thanks.</p>
<p style="margin-top: 0px; margin-bottom: 0px;"><br>
</p>
<p style="margin-top: 0px; margin-bottom: 0px;">Jikui</p>
</div>
</div>
</div>
</div>
</body>
</html>