>From ovs-ofctl(8), in the session of ct(nat).
"nat was introduced in Open vSwitch 2.6.  The first datapath that
implements ct nat support is the one that ships with Linux 4.6."

I think you might want to install openvswitch-datapath-dkms package
after ovs 2.6, or use upstream openvswitch kernel module in Linux
after 4.6.

-Yi-Hung

On Mon, Nov 13, 2017 at 3:36 PM, abhijit herekar <in.abhi...@gmail.com> wrote:
> Looks, like I was giving a wrong command, I corrected it now and did the
> following:
>
> #ovs-ofctl add-flow s1 "ct_state=+new,icmp,in_port=1, actions=ct(commit,
> zone=1, nat(src=10.0.0.240))"
>
> I get the OFPT_ERROR, which means the cmd is not supported, so I guess the
> OVS which I am using doesnt support NAT for connection.
>
> So, what is the OVS and Kernel module for connection tracking I should use
> so that it works.
>
>
> Cureently, I have
>
>
> abhijit@abhijit-vhost1:~/work/ovs$ modinfo openvswitch
> filename:
> /lib/modules/4.4.0-93-generic/kernel/net/openvswitch/openvswitch.ko
> license:        GPL
> description:    Open vSwitch switching datapath
> srcversion:     07E134FFF32332DE5699245
> depends:        nf_conntrack,libcrc32c,nf_defrag_ipv6
> intree:         Y
> vermagic:       4.4.0-93-generic SMP mod_unload modversions
> abhijit@abhijit-vhost1:~/work/ovs$ sudo ovs-ofctl add-flow s1
> "ct_state=+new,icmp,in_port=1,actions=ct(commit,zone=1,nat(src=10.0.0.240))"
> OFPT_ERROR (xid=0x4): OFPBAC_BAD_TYPE
> NXT_FLOW_MOD (xid=0x4):
> (***truncated to 64 bytes from 128***)
> 00000000  01 04 00 80 00 00 00 04-00 00 23 20 00 00 00 0d |..........# ....|
> 00000010  00 00 00 00 00 00 00 00-00 00 00 00 00 00 80 00 |................|
> 00000020  ff ff ff ff ff ff 00 00-00 1d 00 00 00 00 00 00 |................|
> 00000030  00 00 00 02 00 01 00 00-06 02 08 00 00 00 0c 01 |................|
> abhijit@abhijit-vhost1:~/work/ovs$ ovs-vswitchd --version
> ovs-vswitchd (Open vSwitch) 2.6.0
>
>
> On Mon, Nov 13, 2017 at 2:34 PM, abhijit herekar <in.abhi...@gmail.com>
> wrote:
>>
>> hi,
>>
>> I new to the OVS connection tracking, I am trying to add the following
>> flow and get the ERROR
>>
>> #ovs-ofctl add-flow s1 "in_port=1, actions=ct(commit,
>> nat(src=10.0.0.240-10.0.0.254))"
>> #ovs-ofctl: actions are invalid with specified match
>> (OFPBAC_MATCH_INCONSISTENT)
>>
>> I am not able to figure out what is the correct match for the action, I
>> want to SNAT all the packets coming on in_port=1.
>>
>> Please, let me know how to go about this.
>>
>> Thanks
>>
>>
>> --
>> Thanks
>> Abhijit Herekar
>> Trojan!!!! FIGHT ON!!!!!
>
>
>
>
> --
> Thanks
> Abhijit Herekar
> Trojan!!!! FIGHT ON!!!!!
>
> _______________________________________________
> discuss mailing list
> disc...@openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-discuss
>
_______________________________________________
discuss mailing list
disc...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-discuss

Reply via email to