[vpp-dev] Understanding policer configuration

2019-01-09 Thread Raj
Hello all,

I am trying to set up policing in VPP, using RESTCONF. The postman
collections provided by hc2vpp gives the parameters and requests that
needs to be made to configure policing.

While configuring I do not understand what classifier table and
classifier session is. classify table has a mask parameter and session
has a match parameter, what do they do?

The example shows how to configure policing for one IP address, what
needs to be done to configure it for another IP address or a network?

Thanks and Regards,

Raj
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11894): https://lists.fd.io/g/vpp-dev/message/11894
Mute This Topic: https://lists.fd.io/mt/28993544/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [vpp-dev] Using prefetch and buffer_enqueue

2019-01-09 Thread Raj
On Wed, Jan 9, 2019 at 4:18 PM Damjan Marion  wrote:
>> On 9 Jan 2019, at 09:53, Raj  wrote:
>> 1.   static_always_inline void
>>   vlib_buffer_enqueue_to_next (vlib_main_t * vm, vlib_node_runtime_t * node,
>>u32 * buffers, u16 * nexts, uword count)
>>
>
> This function simply gets array of buffer indices and array of next indices,
> and enqueues those buffers to be processed by those next nodes...

Is this function only used in the case of feature arc, where some
packets satisfies certain criteria and moves to a different node?
Basically from where do we get the array of next indices?

Also in the code certain macros CLIB_HAVE_VEC128, CLIB_HAVE_VEC256 and
CLIB_HAVE_VEC512 are defined. I could not figure out what these do.

>> type can be either LOAD or STORE. What is the purpose of these two 
>> operations?
> On x86, there was only load prefetch for a long time, recently store prefetch 
> is introduced
> with Skylake microarchitecture. You can find explanation here:

Based on code walkthrough, one thing I have observed is where ever
.function is defined, static binding happens. In other nodes, dynamic
binding based on the macro VLIB_NODE_FN happens. So If I understand
correctly, we have to use STORE in the latter case. But we can use
LOAD as well. There is no hard and fast rule. Please correct me if I'm
wrong.

Thanks and Regards,

Raj
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11893): https://lists.fd.io/g/vpp-dev/message/11893
Mute This Topic: https://lists.fd.io/mt/28982509/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [vpp-dev] Question about #16465 patch

2019-01-09 Thread Damjan Marion via Lists.Fd.Io


> On 9 Jan 2019, at 16:38, Alexander Chernavin  wrote:
> 
> Hello,
> I have a question about this path: https://gerrit.fd.io/r/#/c/16465/ 
> 
> 
> There was a comment about used terminology ("dev instance" vs "ID") that I 
> addressed but no further actions after this.
> 
> Can you clarify what would be needed to get the patch accepted?

I removed -2, if Steven is ok I can merge it

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11892): https://lists.fd.io/g/vpp-dev/message/11892
Mute This Topic: https://lists.fd.io/mt/28985903/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[vpp-dev] VPP Release 19.01 F0 has arrived

2019-01-09 Thread Andrew Yourtchenko
Hello all,

The API freeze day and time has come! [1]

This means only low-risk changes are accepted on the main branch until
it reopens again.

I will send a separate announcement when that happens.

--a

[1] https://wiki.fd.io/view/Projects/vpp/Release_Plans/Release_Plan_19.01
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11891): https://lists.fd.io/g/vpp-dev/message/11891
Mute This Topic: https://lists.fd.io/mt/28986766/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[vpp-dev] Question about #16465 patch

2019-01-09 Thread Alexander Chernavin
Hello,
I have a question about this path: https://gerrit.fd.io/r/#/c/16465/

There was a comment about used terminology ("dev instance" vs "ID") that I
addressed but no further actions after this.

Can you clarify what would be needed to get the patch accepted?

Thanks,
Alexander
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11890): https://lists.fd.io/g/vpp-dev/message/11890
Mute This Topic: https://lists.fd.io/mt/28985903/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread Ole Troan
Hi,

so you have checked:
 - trace (show trace) after enabling trace on the input node
 - show errors
 - interface counters

Apart from firing up the debugger I’m running out of suggestions.
Can you get plain (non-NAT) IPfix to work? 

Cheers,
Ole

> On 9 Jan 2019, at 14:04, emma sdi  wrote:
> 
> Dear Fabian,
> 
> I checked the output of "sh int" command and ipfix flush command didn't't 
> change tx packets counters. it seems this command don't work! 
> Anyway thanks for taking time and your consideration and help.
> 
> Best Regards,
> 
> On Wed, Jan 9, 2019 at 3:45 PM Matus Fabian -X (matfabia - PANTHEON 
> TECHNOLOGIES at Cisco)  wrote:
> Hi,
> 
>  
> 
> VPP configuration look good to me, I am not sure what is wrong. Maybe try to 
> check “show interface” output, IPfix should add 9 additional tx packets for 
> GigabitEthernet3/0/0 after ping and “ipfix flush” command.
> 
>  
> 
> Matus
> 
>  
> 
>  
> 
> From: vpp-dev@lists.fd.io  On Behalf Of emma sdi
> Sent: Wednesday, January 9, 2019 12:32 PM
> To: vpp-dev@lists.fd.io
> Subject: Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging
> 
>  
> 
> Dear Fabian,
> 
> Unfortunately, the collector counter is still stuck to zero (no ipfix packets 
> received).
> I would like to check my topology and configuration with you. thanks in 
> advance.
> 
> Client1 IP: 2.2.2.2
> Client2 IP: 3.3.3.3
> 
> DUT config:
> GigabitEthernet3/0/0 (up):
>   L3 2.2.2.1/24
> GigabitEthernetb/0/0 (up):
>   L3 3.3.3.1/24
> 
> vppctl set interface nat44 in GigabitEthernet3/0/0 out GigabitEthernetb/0/0
> vppctl nat44 add address 40.40.40.40 - 40.40.40.254
> vppctl set ipfix exporter collector 2.2.2.2 port 4739 src 2.2.2.1
> vppctl nat ipfix logging
> 
> Client1: nfcapd -l /root/log/ -E -p 4739
> 
> client1 ping client2 successfully. the src addr of echo packets in DUT is 
> changed to 40.40.4 0.254 and also in return path, the destination of reply 
> packets is changed to original address again. I mean we have the correct nat 
> functionality. but about ipfix, the collector doesn't receive any log. I 
> checked it by tcpdump and nfcapd.
> 
> Best Regards,
> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> 
> View/Reply Online (#11888): https://lists.fd.io/g/vpp-dev/message/11888
> Mute This Topic: https://lists.fd.io/mt/28911869/675193
> Group Owner: vpp-dev+ow...@lists.fd.io
> Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [otr...@employees.org]
> -=-=-=-=-=-=-=-=-=-=-=-

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11889): https://lists.fd.io/g/vpp-dev/message/11889
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread emma sdi
Dear Fabian,

I checked the output of "sh int" command and ipfix flush command didn't't
change tx packets counters. it seems this command don't work!
Anyway thanks for taking time and your consideration and help.

Best Regards,

On Wed, Jan 9, 2019 at 3:45 PM Matus Fabian -X (matfabia - PANTHEON
TECHNOLOGIES at Cisco)  wrote:

> Hi,
>
>
>
> VPP configuration look good to me, I am not sure what is wrong. Maybe try
> to check “show interface” output, IPfix should add 9 additional tx packets
> for GigabitEthernet3/0/0 after ping and “ipfix flush” command.
>
>
>
> Matus
>
>
>
>
>
> *From:* vpp-dev@lists.fd.io  *On Behalf Of *emma sdi
> *Sent:* Wednesday, January 9, 2019 12:32 PM
> *To:* vpp-dev@lists.fd.io
> *Subject:* Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging
>
>
>
> Dear Fabian,
>
> Unfortunately, the collector counter is still stuck to zero (no ipfix
> packets received).
> I would like to check my topology and configuration with you. thanks in
> advance.
>
> Client1 IP: 2.2.2.2
> Client2 IP: 3.3.3.3
>
> DUT config:
> GigabitEthernet3/0/0 (up):
>   L3 2.2.2.1/24
> GigabitEthernetb/0/0 (up):
>   L3 3.3.3.1/24
>
> vppctl set interface nat44 in GigabitEthernet3/0/0 out GigabitEthernetb/0/0
> vppctl nat44 add address 40.40.40.40 - 40.40.40.254
> vppctl set ipfix exporter collector 2.2.2.2 port 4739 src 2.2.2.1
> vppctl nat ipfix logging
>
> Client1: nfcapd -l /root/log/ -E -p 4739
>
> client1 ping client2 successfully. the src addr of echo packets in DUT is
> changed to 40.40.4 0.254 and also in return path, the destination of reply
> packets is changed to original address again. I mean we have the correct
> nat functionality. but about ipfix, the collector doesn't receive any log.
> I checked it by tcpdump and nfcapd.
>
> Best Regards,
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11888): https://lists.fd.io/g/vpp-dev/message/11888
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[vpp-dev] Coverity Scan Update

2019-01-09 Thread Dave Barach via Lists.Fd.Io
Follow-up from yesterday's project call... See 
https://community.synopsys.com/s/article/Coverity-Scan-Update

Executive summary, extracted from the URL shown above:

"On Monday, January 7, 2019 our team was notified that our Coverity Scan 
hosting service provider unexpectedly ceased operations, making the servers 
that support Scan unavailable. We are working to stand up new servers to 
restore the service as soon as possible. We apologize for any inconvenience."

Oops.
 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11887): https://lists.fd.io/g/vpp-dev/message/11887
Mute This Topic: https://lists.fd.io/mt/28983703/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [vpp-dev] wwan0 intarface - vpp

2019-01-09 Thread Dave Barach via Lists.Fd.Io
+1, bridging the interface also enables direct use of wpa_supplicant to do the 
authentication dance.

D.

From: Jim Thompson 
Sent: Tuesday, January 8, 2019 6:39 PM
To: Dave Barach (dbarach) 
Cc: dmar...@me.com; amitmulay...@gmail.com; vpp-dev@lists.fd.io
Subject: Re: [vpp-dev] wwan0 intarface - vpp


There is a DPDK driver for Atheros 10K NICs (the QCA986x/988x is Ath 10k).

https://github.com/telematik-tu-ilmenau/DPDK-WiFi  (specifically 
/drivers/net/ath10k, written for DPDK 17.10)

I don’t know anything about the quality or performance of this driver.   VPP 
would also need to know how to configure and monitor this NIC.
Seems like a lot of work for minimal gains, so Dave’ suggestion of bridging 
into a tap-v2 interface is likely to provide more immediate results.

As for performance of same, anyone looking for > circa 600Mbps with wireless is 
smoking something interesting.  Pretty sure tap-v2 can pass that.

Jim




On Jan 8, 2019, at 1:57 PM, Dave Barach via Lists.Fd.Io 
mailto:dbarach=cisco@lists.fd.io>> wrote:

+1. You can put the [linux kernel] wireless interface into a Linux bridge with 
a vpp tap-v2 interface. Performance might not be much to write home about...

D.

From: vpp-dev@lists.fd.io 
mailto:vpp-dev@lists.fd.io>> On Behalf Of Damjan Marion 
via Lists.Fd.Io
Sent: Tuesday, January 8, 2019 12:13 PM
To: amitmulay...@gmail.com
Cc: vpp-dev@lists.fd.io
Subject: Re: [vpp-dev] wwan0 intarface - vpp





On 7 Jan 2019, at 16:03, amitmulay...@gmail.com 
wrote:

Hello all , im new to vpp and just started to reseach about it

i was wandering regarding an issue , i want that the vpp will recognaize in his 
port list
a wwan0 intarface (wifi) that i have in the linux device.
it has its own pci address ,i can see it under sudo lshw -class network -businfo
pci@:01:00.0  wlan0  networkQCA986x/988x 
802.11ac Wireless Network A

but the vpp dosent "take it"

can i make it happen?

We don't support wireless NICs and AFAIK there is no user mode drivers 
available for wireless NICs.
--
Damjan

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11872): https://lists.fd.io/g/vpp-dev/message/11872
Mute This Topic: https://lists.fd.io/mt/28963384/675164
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  
[j...@netgate.com]
-=-=-=-=-=-=-=-=-=-=-=-

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11886): https://lists.fd.io/g/vpp-dev/message/11886
Mute This Topic: https://lists.fd.io/mt/28963384/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [vpp-dev] VPP 19.01 C API gets segmentation fault #binapi #vpp #vppcapi

2019-01-09 Thread Dave Barach via Lists.Fd.Io
NP, we’ve seen that one before, glad things are working properly now... D.

From: vpp-dev@lists.fd.io  On Behalf Of Anthony Linz
Sent: Wednesday, January 9, 2019 1:15 AM
To: vpp-dev@lists.fd.io
Subject: Re: [vpp-dev] VPP 19.01 C API gets segmentation fault #binapi #vpp 
#vppcapi

Dear Dave,
Thank you very much for your great and exact response.
The program now works like a dream.
Best wishes,
--
Anthony
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11885): https://lists.fd.io/g/vpp-dev/message/11885
Mute This Topic: https://lists.fd.io/mt/28972181/21656
Mute #vpp: https://lists.fd.io/mk?hashtag=vpp=1480452
Mute #binapi: https://lists.fd.io/mk?hashtag=binapi=1480452
Mute #vppcapi: https://lists.fd.io/mk?hashtag=vppcapi=1480452
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread Matus Fabian -X (matfabia - PANTHEON TECHNOLOGIES@Cisco) via Lists.Fd.Io
Hi,

VPP configuration look good to me, I am not sure what is wrong. Maybe try to 
check “show interface” output, IPfix should add 9 additional tx packets for 
GigabitEthernet3/0/0 after ping and “ipfix flush” command.

Matus


From: vpp-dev@lists.fd.io  On Behalf Of emma sdi
Sent: Wednesday, January 9, 2019 12:32 PM
To: vpp-dev@lists.fd.io
Subject: Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

Dear Fabian,

Unfortunately, the collector counter is still stuck to zero (no ipfix packets 
received).
I would like to check my topology and configuration with you. thanks in advance.

Client1 IP: 2.2.2.2
Client2 IP: 3.3.3.3

DUT config:
GigabitEthernet3/0/0 (up):
  L3 2.2.2.1/24
GigabitEthernetb/0/0 (up):
  L3 3.3.3.1/24

vppctl set interface nat44 in GigabitEthernet3/0/0 out GigabitEthernetb/0/0
vppctl nat44 add address 40.40.40.40 - 40.40.40.254
vppctl set ipfix exporter collector 2.2.2.2 port 4739 src 2.2.2.1
vppctl nat ipfix logging

Client1: nfcapd -l /root/log/ -E -p 4739

client1 ping client2 successfully. the src addr of echo packets in DUT is 
changed to 40.40.4 0.254 and also in return path, the destination of reply 
packets is changed to original address again. I mean we have the correct nat 
functionality. but about ipfix, the collector doesn't receive any log. I 
checked it by tcpdump and nfcapd.

Best Regards,
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11884): https://lists.fd.io/g/vpp-dev/message/11884
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread emma sdi
Dear Fabian,

Unfortunately, the collector counter is still stuck to zero (no ipfix packets 
received).
I would like to check my topology and configuration with you. thanks in advance.

Client1 IP: 2.2.2.2
Client2 IP: 3.3.3.3

DUT config:
GigabitEthernet3/0/0 (up):
  L3 2.2.2.1/24
GigabitEthernetb/0/0 (up):
  L3 3.3.3.1/24

vppctl set interface nat44 in GigabitEthernet3/0/0 out GigabitEthernetb/0/0
vppctl nat44 add address 40.40.40.40 - 40.40.40.254
vppctl set ipfix exporter collector 2.2.2.2 port 4739 src 2.2.2.1
vppctl nat ipfix logging

Client1: nfcapd -l /root/log/ -E -p 4739

client1 ping client2 successfully. the src addr of echo packets in DUT is 
changed to 40.40.4 0.254 and also in return path, the destination of reply 
packets is changed to original address again. I mean we have the correct nat 
functionality. but about ipfix, the collector doesn't receive any log. I 
checked it by tcpdump and nfcapd.

Best Regards,
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11883): https://lists.fd.io/g/vpp-dev/message/11883
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [vpp-dev] Using prefetch and buffer_enqueue

2019-01-09 Thread Damjan Marion via Lists.Fd.Io


> On 9 Jan 2019, at 09:53, Raj  wrote:
> 
> Hello all,
> 
> While going through the VPP code, I have not fully understood  what
> the following functions mean and when should they be used?
> 
> 1.   static_always_inline void
>   vlib_buffer_enqueue_to_next (vlib_main_t * vm, vlib_node_runtime_t * node,
>u32 * buffers, u16 * nexts, uword count)
> 
>   I could see following comments about this function
>   /*
>* Send the packets along their respective next-node graph arcs
>* Considerable locality of reference is expected, most if not all
>* packets in the inbound vector will traverse the same next-node
>* arc
>*/
> I tried reading through the code but could not figure out what this
> function does, and how this is implemented. I see that the code has
> optimizations for various CPU, but not could not figure out what those
> optimizations are.

This function simply gets array of buffer indices and array of next indices,
and enqueues those buffers to be processed by those next nodes...


> 
> 2.  #define vlib_prefetch_buffer_header(b, type )
>   CLIB_PREFETCH (b, 64, type)
> 
> This gets expanded to:
> #define _CLIB_PREFETCH(n,size,type) \
>  if ((size) > (n)*CLIB_CACHE_LINE_BYTES)   \
>__builtin_prefetch (_addr + (n)*CLIB_CACHE_LINE_BYTES,  \
>CLIB_PREFETCH_##type,   \
>/* locality */ 3);
> 
> type can be either LOAD or STORE. What is the purpose of these two operations?
> 
> I am sure I am missing some thing with respect to understanding
> prefetch. I assume LOAD will prefetch data from memory, and STORE
> performs its inverse operation?


On x86, there was only load prefetch for a long time, recently store prefetch 
is introduced
with Skylake microarchitecture. You can find explanation here:

https://www.felixcloutier.com/x86/prefetchwt1 


Please note that compiler will emit PREFETCHWT1 instruction only if your
code is using multi-versioning in VPP (use of VLIB_NODE_FN() macro + 
MULTIARCH_SOURCES in CMakeLists.txt file).
and only when skylake is detected on runtime.

Otherwise CLIB_PREFETCH (x, 64, STORE) will produce identical results 
like you did LOAD

-- 
Damjan

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11882): https://lists.fd.io/g/vpp-dev/message/11882
Mute This Topic: https://lists.fd.io/mt/28982509/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [vpp-dev] Performance Improvement

2019-01-09 Thread Damjan Marion via Lists.Fd.Io


> On 9 Jan 2019, at 10:24, Gunaseelan Venkatachary - ERS, HCL Tech 
>  wrote:
> 
> Hello Team 
> Wish to reach out to bigger audience for some support in terms of performance 
> fine tuning, the context being , We are trying to insert a sample node, in 
> addition to whats already available in VPP, both in RX and TX interfaces, 
> using feature ARC ( like after device_input node in Rx) . 
>  
> We are facing some performance issues in that , since in this case we use 
> memcpy and byte order operations(using libc apis ), we suspect these 2 may be 
> causing issues , also found that vpp clib has similar apis too,  hence is it 
> better to use vpp clib apis instead of libc apis to get better performance ?

Likely, try to use clib_memcpy_fast() instead. Typically you wan't to avoid 
function calls in dataplane code, so our implementations are inline 
functions

What "show run" says about your node during the heavy load? (don't forget to do 
"clear run" after traffic is started)

>  
> We observe good amount of rx_miss in show interface command, instead of drop 
> , any clues ?

rx miss typically happens when there is more incoming traffic than what VPP can 
process...


>  
> Also wish to know are there any known methods (Dos/Donts in VPP) for 
> performance tuning.

For a start try to use our standard node coding pattern we use, like in 
sample-plugin.

-- 
Damjan

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11881): https://lists.fd.io/g/vpp-dev/message/11881
Mute This Topic: https://lists.fd.io/mt/28982608/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[vpp-dev] Performance Improvement

2019-01-09 Thread Gunaseelan Venkatachary - ERS, HCL Tech
Hello Team
Wish to reach out to bigger audience for some support in terms of performance 
fine tuning, the context being , We are trying to insert a sample node, in 
addition to whats already available in VPP, both in RX and TX interfaces, using 
feature ARC ( like after device_input node in Rx) .

We are facing some performance issues in that , since in this case we use 
memcpy and byte order operations(using libc apis ), we suspect these 2 may be 
causing issues , also found that vpp clib has similar apis too,  hence is it 
better to use vpp clib apis instead of libc apis to get better performance ?

We observe good amount of rx_miss in show interface command, instead of drop , 
any clues ?

Also wish to know are there any known methods (Dos/Donts in VPP) for 
performance tuning.


Best Regards
Gunaseelan V
98408 60856

::DISCLAIMER::
--
The contents of this e-mail and any attachment(s) are confidential and intended 
for the named recipient(s) only. E-mail transmission is not guaranteed to be 
secure or error-free as information could be intercepted, corrupted, lost, 
destroyed, arrive late or incomplete, or may contain viruses in transmission. 
The e mail and its contents (with or without referred errors) shall therefore 
not attach any liability on the originator or HCL or its affiliates. Views or 
opinions, if any, presented in this email are solely those of the author and 
may not necessarily reflect the views or opinions of HCL or its affiliates. Any 
form of reproduction, dissemination, copying, disclosure, modification, 
distribution and / or publication of this message without the prior written 
consent of authorized representative of HCL is strictly prohibited. If you have 
received this email in error please delete it and notify the sender 
immediately. Before opening any email and/or attachments, please check them for 
viruses and other defects.
--
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11880): https://lists.fd.io/g/vpp-dev/message/11880
Mute This Topic: https://lists.fd.io/mt/28982608/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread Matus Fabian -X (matfabia - PANTHEON TECHNOLOGIES@Cisco) via Lists.Fd.Io
https://wiki.fd.io/view/VPP/NAT#Enable_NAT_plugin_IPFIX_logging_example

You can also take a look at NAT plugin test 
https://gerrit.fd.io/r/gitweb?p=vpp.git;a=blob;f=test/test_nat.py;h=c64359a4db743ebf187c4198a12b2e3c80f5433d;hb=HEAD#l2646

Matus


From: khers 
Sent: Wednesday, January 9, 2019 9:48 AM
To: Matus Fabian -X (matfabia - PANTHEON TECHNOLOGIES at Cisco) 

Subject: Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

Dear Fabian,
No. my collector don't receive any thing. I would appreciate if you could give 
me a valid config for ipfix logging.
Warm Regards,

On Mon, Jan 7, 2019 at 9:16 AM Matus Fabian -X (matfabia - PANTHEON 
TECHNOLOGIES at Cisco) mailto:matfa...@cisco.com>> wrote:
Hi,

Do you receive at least IPfix templates on collector?

Matus


From: khers mailto:s3m2e1.6s...@gmail.com>>
Sent: Sunday, January 6, 2019 8:58 AM
To: Matus Fabian -X (matfabia - PANTHEON TECHNOLOGIES at Cisco) 
mailto:matfa...@cisco.com>>
Cc: vpp-dev mailto:vpp-dev@lists.fd.io>>
Subject: Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

Hi,
I tried that but I didn't get any log from IPFIX
Thanks
Regards

On Wed, Jan 2, 2019 at 9:31 AM Matus Fabian -X (matfabia - PANTHEON 
TECHNOLOGIES at Cisco) mailto:matfa...@cisco.com>> wrote:
Hi,

IPfix events are aggregated, to send it immediately use “ipfix flush"

Matus


From: vpp-dev@lists.fd.io 
mailto:vpp-dev@lists.fd.io>> On Behalf Of emma sdi
Sent: Tuesday, December 25, 2018 1:49 PM
To: vpp-dev mailto:vpp-dev@lists.fd.io>>
Subject: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

Dear Vpp,
I'd just configured a simple snat to check logging nat with IPFIX.I have a 
router which vpp installed and two debian machines which one of them is IPFIX 
collector.
Here it is the topology:
https://paste.ubuntu.com/p/Hb9vpPhq67/

 The IPFIX collector software is nfcapd. I defined a ip pool with  range 
40.40.40.40-40.40.40.254:
nat44 add address 40.40.40.40 - 40.40.40.254
The interface of vpp side has ip 10.10.10.208 and the interface of collector 
side has ip 10.10.10.205
I defined ipfix collector with this command:
   set ipfix exporter collector 10.10.10.205 src 10.10.10.208
I enabled nat ipfix logging with this command:
nat ipfix logging

The ipfix collector software in client1 is ran with this command:
  nfcapd -l /root/log/ -E
I send ping from client1 to client2 . The ping has echo and reply and the 
natting process is done as I send the output of vpp trace here:
https://paste.ubuntu.com/p/HkMqSXy5tN/

But there aren't any IPFIX log on the output of nfcapd.
Could you please tell me what should I do for collecting nat logs with IPFIX.
Thanks
Regards
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11879): https://lists.fd.io/g/vpp-dev/message/11879
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[vpp-dev] Using prefetch and buffer_enqueue

2019-01-09 Thread Raj
 Hello all,

While going through the VPP code, I have not fully understood  what
the following functions mean and when should they be used?

1.   static_always_inline void
   vlib_buffer_enqueue_to_next (vlib_main_t * vm, vlib_node_runtime_t * node,
u32 * buffers, u16 * nexts, uword count)

   I could see following comments about this function
   /*
* Send the packets along their respective next-node graph arcs
* Considerable locality of reference is expected, most if not all
* packets in the inbound vector will traverse the same next-node
* arc
*/
I tried reading through the code but could not figure out what this
function does, and how this is implemented. I see that the code has
optimizations for various CPU, but not could not figure out what those
optimizations are.

2.  #define vlib_prefetch_buffer_header(b, type )
   CLIB_PREFETCH (b, 64, type)

This gets expanded to:
#define _CLIB_PREFETCH(n,size,type) \
  if ((size) > (n)*CLIB_CACHE_LINE_BYTES)   \
__builtin_prefetch (_addr + (n)*CLIB_CACHE_LINE_BYTES,  \
CLIB_PREFETCH_##type,   \
/* locality */ 3);

type can be either LOAD or STORE. What is the purpose of these two operations?

I am sure I am missing some thing with respect to understanding
prefetch. I assume LOAD will prefetch data from memory, and STORE
performs its inverse operation?

Thanks and Regards,

Raj
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11878): https://lists.fd.io/g/vpp-dev/message/11878
Mute This Topic: https://lists.fd.io/mt/28982509/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread emma sdi
[Edited Message Follows]

Dear Fabian,
No. my collector doesn't receive any thing. I would appreciate if you could 
give me a valid config for ipfix logging.

Warm Regards
On Mon, Jan 7, 2019 at 9:16 AM Matus Fabian -X (matfabia - PANTHEON 
TECHNOLOGIES at Cisco) < matfa...@cisco.com > wrote:

> 
> 
> 
> Hi,
> 
> 
> 
>  
> 
> 
> 
> Do you receive at least IPfix templates on collector?
> 
> 
> 
>  
> 
> 
> 
> Matus
> 
> 
> 
>  
> 
> 
> 
>  
> 
> 
> 
> *From:* khers < s3m2e1.6s...@gmail.com >
> *Sent:* Sunday, January 6, 2019 8:58 AM
> *To:* Matus Fabian -X (matfabia - PANTHEON TECHNOLOGIES at Cisco) < 
> matfa...@cisco.com
> >
> *Cc:* vpp-dev < vpp-dev@lists.fd.io >
> *Subject:* Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging
> 
> 
> 
>  
> 
> 
> 
> Hi,
> 
> 
> 
> I tried that but I didn't get any log from IPFIX
> 
> 
> 
> 
> Thanks
> 
> 
> 
> 
> Regards
> 
> 
> 
> 
>  
> 
> 
> 
> On Wed, Jan 2, 2019 at 9:31 AM Matus Fabian -X (matfabia - PANTHEON
> TECHNOLOGIES at Cisco) < matfa...@cisco.com > wrote:
> 
> 
> 
>> 
>> 
>> Hi,
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> IPfix events are aggregated, to send it immediately use “ipfix flush"
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> Matus
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> *From:* vpp-dev@lists.fd.io < vpp-dev@lists.fd.io > *On Behalf Of* emma sdi
>> 
>> *Sent:* Tuesday, December 25, 2018 1:49 PM
>> *To:* vpp-dev < vpp-dev@lists.fd.io >
>> *Subject:* [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> Dear Vpp,
>> 
>> 
>> 
>> I'd just configured a simple snat to check logging nat with IPFIX.I have a
>> router which vpp installed and two debian machines which one of them is
>> IPFIX collector.
>> 
>> 
>> 
>> 
>> Here it is the topology:
>> 
>> 
>> 
>> 
>> https://paste.ubuntu.com/p/Hb9vpPhq67/
>> 
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> 
>>  The IPFIX collector software is nfcapd. I defined a ip pool with  range
>> 40.40.40.40-40.40.40.254:
>> 
>> 
>> 
>> 
>>    *nat44 add address 40.40.40.40 - 40.40.40.254*
>> 
>> 
>> 
>> 
>> The interface of vpp side has ip 10.10.10.208 and the interface of
>> collector side has ip 10.10.10.205
>> 
>> 
>> 
>> 
>> I defined ipfix collector with this command:
>> 
>> 
>> 
>> 
>> *   set ipfix exporter collector 10.10.10.205 src 10.10.10.208*
>> 
>> 
>> 
>> 
>> I enabled nat ipfix logging with this command:
>> 
>> 
>> 
>> 
>> *nat ipfix logging*
>> 
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> 
>> The ipfix collector software in client1 is ran with this command:
>> 
>> 
>> 
>> 
>> *  nfcapd -l /root/log/ -E*
>> 
>> 
>> 
>> 
>> I send ping from *client1* to *client2*. The ping has echo and reply and
>> the natting process is done as I send the output of vpp trace here:
>> 
>> 
>> 
>> 
>> https://paste.ubuntu.com/p/HkMqSXy5tN/
>> 
>> 
>> 
>> 
>>  
>> 
>> 
>> 
>> 
>> But there aren't any IPFIX log on the output of nfcapd.
>> 
>> 
>> 
>> 
>> Could you please tell me what should I do for collecting nat logs with
>> IPFIX.
>> 
>> 
>> 
>> 
>> Thanks
>> 
>> 
>> 
>> 
>> Regards
>> 
>> 
>> 
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11877): https://lists.fd.io/g/vpp-dev/message/11877
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging

2019-01-09 Thread emma sdi
Dear Fabian,
No. my collector don't receive any thing. I would appreciate if you could
give me a valid config for ipfix logging.

Warm Regards

On Mon, Jan 7, 2019 at 9:16 AM Matus Fabian -X (matfabia - PANTHEON
TECHNOLOGIES at Cisco)  wrote:

> Hi,
>
>
>
> Do you receive at least IPfix templates on collector?
>
>
>
> Matus
>
>
>
>
>
> *From:* khers 
> *Sent:* Sunday, January 6, 2019 8:58 AM
> *To:* Matus Fabian -X (matfabia - PANTHEON TECHNOLOGIES at Cisco) <
> matfa...@cisco.com>
> *Cc:* vpp-dev 
> *Subject:* Re: [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging
>
>
>
> Hi,
>
> I tried that but I didn't get any log from IPFIX
>
> Thanks
>
> Regards
>
>
>
> On Wed, Jan 2, 2019 at 9:31 AM Matus Fabian -X (matfabia - PANTHEON
> TECHNOLOGIES at Cisco)  wrote:
>
> Hi,
>
>
>
> IPfix events are aggregated, to send it immediately use “ipfix flush"
>
>
>
> Matus
>
>
>
>
>
> *From:* vpp-dev@lists.fd.io  *On Behalf Of *emma sdi
> *Sent:* Tuesday, December 25, 2018 1:49 PM
> *To:* vpp-dev 
> *Subject:* [SUSPECTED SPAM] [vpp-dev] IPFIX Nat Logging
>
>
>
> Dear Vpp,
>
> I'd just configured a simple snat to check logging nat with IPFIX.I have a
> router which vpp installed and two debian machines which one of them is
> IPFIX collector.
>
> Here it is the topology:
>
> https://paste.ubuntu.com/p/Hb9vpPhq67/
>
>
>
>  The IPFIX collector software is nfcapd. I defined a ip pool with  range
> 40.40.40.40-40.40.40.254:
>
> *nat44 add address 40.40.40.40 - 40.40.40.254*
>
> The interface of vpp side has ip 10.10.10.208 and the interface of
> collector side has ip 10.10.10.205
>
> I defined ipfix collector with this command:
>
> *   set ipfix exporter collector 10.10.10.205 src 10.10.10.208*
>
> I enabled nat ipfix logging with this command:
>
> *nat ipfix logging*
>
>
>
> The ipfix collector software in client1 is ran with this command:
>
> *  nfcapd -l /root/log/ -E*
>
> I send ping from *client1* to *client2* . The ping has echo and reply and
> the natting process is done as I send the output of vpp trace here:
>
> https://paste.ubuntu.com/p/HkMqSXy5tN/
>
>
>
> But there aren't any IPFIX log on the output of nfcapd.
>
> Could you please tell me what should I do for collecting nat logs with
> IPFIX.
>
> Thanks
>
> Regards
>
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11877): https://lists.fd.io/g/vpp-dev/message/11877
Mute This Topic: https://lists.fd.io/mt/28911869/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[vpp-dev] Mellanox ConnectX-4 Lx cards binding with DPDK, but not recognized by VPP #vpp

2019-01-09 Thread Nixon Raj via Lists.Fd.Io
*Setup:*

·Platform – GNU/Linux

·Kernel – 4.4.0-131-generic

·Processor – x86_64

·OS - Ubuntu 16.04

 

*MLNX_OFED Driver Version :*

·4.1-1.0.2.0

Followed link :
https://community.mellanox.com/s/article/how-to-build-vpp-fd-io--160--development-environment-with-mellanox-dpdk-pmd-for-connectx-4-and-connectx-5

Installation Successful and bind to DPDK with vfio-pci, but not recognized by 
VPP
# vppctl sh pci 
address      Sock VID:PID     Link Speed   Driver          Product Name         
           Vital Product Data

     :02:00.0      15b3:1015   8.0 GT/s x4  vfio-pci

     :02:00.1      15b3:1015   8.0 GT/s x4  vfio-pci  

     :03:00.0      15b3:1015   8.0 GT/s x4  vfio-pci

     :03:00.1      15b3:1015   8.0 GT/s x4  vfio-pci 

     :04:00.0      8086:1539   2.5 GT/s x1  igb

     :05:00.0      8086:1539   2.5 GT/s x1  igb  

0   000:06:00.0      8086:1539   2.5 GT/s x1  igb

     :07:00.0      8086:1539   2.5 GT/s x1  igb

 

     :08:00.0      8086:1539   2.5 GT/s x1  igb

#vppctl sh int

          Name               Idx       State          Counter          Count

 

          local0                            0        down

 

A
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11876): https://lists.fd.io/g/vpp-dev/message/11876
Mute This Topic: https://lists.fd.io/mt/28982352/21656
Mute #vpp: https://lists.fd.io/mk?hashtag=vpp=1480452
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-