<div dir="ltr">Hi Wang,<div><br></div><div>Could you upload your patch to ovs? I would appreciate your help about that case ^^. Thank you.</div></div><br><div class="gmail_quote"><div dir="ltr">Vào CN, 13 thg 1, 2019 vào lúc 04:36 wang junqiang &lt;<a href="mailto:wangjq_china@outlook.com">wangjq_china@outlook.com</a>&gt; đã viết:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">



<div>
<div>
<div>
<div>
<div style="direction:ltr">Hi,</div>
<div style="direction:ltr">    I also encountered this problem, need to change the source code to solve.</div>
</div>
<div><br>
</div>
<div class="gmail-m_5057710210686132458ms-outlook-ios-signature">获取 <a href="https://aka.ms/o0ukef" target="_blank">Outlook for iOS</a></div>
</div>
<div> </div>
<hr style="display:inline-block;width:98%">
<div id="gmail-m_5057710210686132458divRplyFwdMsg" dir="dir=&quot;ltr&quot;"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>发件人:</b> <a href="mailto:ovs-discuss-bounces@openvswitch.org" target="_blank">ovs-discuss-bounces@openvswitch.org</a> 代表 Hoàng Công Phước &lt;<a href="mailto:hoangphuocbk2.07@gmail.com" target="_blank">hoangphuocbk2.07@gmail.com</a>&gt;<br>
<b>发送时间:</b> 星期六, 一月 12, 2019 11:11<br>
<b>收件人:</b> Ben Pfaff<br>
<b>抄送:</b> <a href="mailto:bugs@openvswitch.org" target="_blank">bugs@openvswitch.org</a><br>
<b>主题:</b> Re: [ovs-discuss] [SFC NSH] Update &quot;eth_dst&quot; for original packet after decap nsh encapsulation packet.
<div> </div>
</font></div>

<div dir="ltr">
<div dir="ltr">here are the document I am following:
<div><a href="https://github.com/openvswitch/ovs/blob/master/tests/nsh.at#L65-L68" target="_blank">https://github.com/openvswitch/ovs/blob/master/tests/nsh.at#L65-L68</a><br>
</div>
<div>My ovs version is 2.9.0 and when I check ovs, in version 2.9.0, NSH is supported.</div>
<div><br>
</div>
</div>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr">Vào Th 7, 12 thg 1, 2019 vào lúc 01:52 Ben Pfaff &lt;<a href="mailto:blp@ovn.org" target="_blank">blp@ovn.org</a>&gt; đã viết:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I don&#39;t think OVS supports this kind of encapsulation.<br>
<br>
On Fri, Jan 11, 2019 at 10:42:10AM +0900, Hoàng Công Phước wrote:<br>
&gt; Hi Ben, thank for your<br>
&gt; <br>
&gt; I am sorry because I didn&#39;t show the encapsulation command. In this case,<br>
&gt; original packet is encapsulated 2 times, with nsh and ethernet headers.<br>
&gt; Here is the flow:<br>
&gt; <br>
&gt; table=0, n_packets=0, n_bytes=0,<br>
&gt; priority=30,tcp,in_port=&quot;tap09d8de0e-20&quot;,nw_src=10.10.0.111,nw_dst=<br>
&gt; <a href="http://10.10.0.0/24,tp_dst=80" rel="noreferrer" target="_blank">10.10.0.0/24,tp_dst=80</a><br>
&gt; actions=encap(nsh),set_field:0x33-&gt;nsh_spi,set_field:255-&gt;nsh_si,encap(ethernet),set_field:fa:16:3e:05:3a:12-&gt;eth_dst,resubmit(,5)<br>
&gt; <br>
&gt; As I known, after using decap() 2 times, I can get the original packet. So,<br>
&gt; I can update eth_dst to it.<br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt; Vào Th 6, 11 thg 1, 2019 vào lúc 04:32 Ben Pfaff &lt;<a href="mailto:blp@ovn.org" target="_blank">blp@ovn.org</a>&gt; đã viết:<br>
&gt; <br>
&gt; &gt; On Fri, Jan 11, 2019 at 04:26:03AM +0900, Hoàng Công Phước wrote:<br>
&gt; &gt; &gt; Hi experts,<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; I am trying to update &quot;eth_dst&quot; for original packet after decap nsh<br>
&gt; &gt; &gt; encapsulation packet. Here is my command about it:<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; $ sudo ovs-ofctl add-flow br-int &quot;table=10, priority=1, dl_vlan=4,<br>
&gt; &gt; &gt; dl_dst=fa:16:3e:05:3a:12, dl_type=0x894f, nsh_mdtype=1, nsh_spi=0x33,<br>
&gt; &gt; &gt; nsh_si=254, actions=strip_vlan,<br>
&gt; &gt; &gt; move:NXM_OF_ETH_DST-&gt;OXM_OF_PKT_REG0[0..47], decap(), decap(),<br>
&gt; &gt; &gt; move:OXM_OF_PKT_REG0[0..47]-&gt;NXM_OF_ETH_DST, output:tap62c2fc56-14&quot;<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; However, I got an error, that is:<br>
&gt; &gt; &gt; &quot;2019-01-10T19:11:27Z|00001|meta_flow|WARN|destination field eth_dst<br>
&gt; &gt; lacks<br>
&gt; &gt; &gt; correct prerequisites<br>
&gt; &gt; &gt; ovs-ofctl: actions are invalid with specified match<br>
&gt; &gt; &gt; (OFPBAC_MATCH_INCONSISTENT)&quot;<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; If I remove &quot;move:NXM_OF_ETH_DST-&gt;OXM_OF_PKT_REG0[0..47]&quot; and<br>
&gt; &gt; &gt; &quot;move:OXM_OF_PKT_REG0[0..47]-&gt;NXM_OF_ETH_DST&quot;, it worked. So there is an<br>
&gt; &gt; &gt; error with copy eth_dst value from outer to inner packet. I am beginner<br>
&gt; &gt; &gt; with Open vSwitch, so it&#39;s very helpful if someone can help me to figure<br>
&gt; &gt; &gt; the problem out.<br>
&gt; &gt;<br>
&gt; &gt; It looks to me that the first decap removes the NSH header and the<br>
&gt; &gt; second decap removes the Ethernet header.  At that point, there&#39;s no<br>
&gt; &gt; Ethernet destination field to set, so the error seems reasonable.<br>
&gt; &gt;<br>
&gt; <br>
&gt; <br>
&gt; -- <br>
&gt; Hoàng Công Phước<br>
</blockquote>
</div>
<br clear="all">
<div><br>
</div>
-- <br>
<div dir="ltr" class="gmail-m_5057710210686132458gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">Hoàng Công Phước</div>
</div>
</div>
</div>
</div>
</div>

</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr">Hoàng Công Phước</div></div></div></div>