RE: AMD power monitor support

2023-11-29 Thread Pattan, Reshma
Hi Siva,

Thanks for the information.  Could you please clarify below


  1.  So should we see C1 increment in below stats.  Or is it CX?
  2.  Are there any specific kernel boot parameter setting we need?  to get 
into MWAITX.

# cpupower -c 2 monitor

| Mperf  || Idle_Stats
CPU| C0   | Cx   | Freq  || POLL | C1   | C2

Thanks,
Reshma

From: Tummala, Sivaprasad 
Sent: Wednesday, November 29, 2023 11:19 AM
To: Pattan, Reshma ; users@dpdk.org
Subject: RE: AMD power monitor support


[AMD Official Use Only - General]

Hi Reshma,

Yes, with pmd-mgmt="monitor" allows AMD power monitor on Genoa.
You can monitor the same using "cpupower -c  monitor" tool.

Thanks & Regards,
Sivaprasad

From: Pattan, Reshma mailto:reshma.pat...@intel.com>>
Sent: Wednesday, November 29, 2023 4:04 PM
To: Tummala, Sivaprasad 
mailto:sivaprasad.tumm...@amd.com>>; 
users@dpdk.org<mailto:users@dpdk.org>
Subject: AMD power monitor support

Caution: This message originated from an External Source. Use proper caution 
when opening attachments, clicking links, or responding.

Hi Sivaprasad,

I am running dpdk l3fwd-power application in "monitor mode" on AMD Genoa using 
below command.
./dpdk-l3fwd-power -l 1-3 -- -p 0x1 --config="(0,0,2),(0,1,3)" 
--pmd-mgmt=monitor

Does it allow cores to  use DPDK AMD power monitor support  feature based of 
mwaitx 
(https://patchwork.dpdk.org/project/dpdk/patch/20231009140546.862553-3-sivaprasad.tumm...@amd.com/)?
If so how do I confirm if the cores are entering implementation dependant C1 
State. If any pointers please let me know.

Thanks,
Reshma


AMD power monitor support

2023-11-29 Thread Pattan, Reshma
Hi Sivaprasad,

I am running dpdk l3fwd-power application in "monitor mode" on AMD Genoa using 
below command.
./dpdk-l3fwd-power -l 1-3 -- -p 0x1 --config="(0,0,2),(0,1,3)" 
--pmd-mgmt=monitor

Does it allow cores to  use DPDK AMD power monitor support  feature based of 
mwaitx 
(https://patchwork.dpdk.org/project/dpdk/patch/20231009140546.862553-3-sivaprasad.tumm...@amd.com/)?
If so how do I confirm if the cores are entering implementation dependant C1 
State. If any pointers please let me know.

Thanks,
Reshma


RE: Pdump Didn't capture the packet

2021-11-17 Thread Pattan, Reshma


From: 廖書華 
Sent: Wednesday, November 17, 2021 3:11 AM
To: Pattan, Reshma 
Cc: users@dpdk.org
Subject: Re: Pdump Didn't capture the packet

Dear,

Thank you for the information !
I rerun the primary application with the other terminal running pdump, however 
it still can't capture the packet.
As for the logs you mentioned that is printed after the primary application 
terminates. Also, for the primary application log, I can make sure it transmits 
and receives the packet, but pdump still can't capture it.

[Reshma]: Are the pcap captured files empty?  That might need some debugging I 
guess. When you stop the pdump application you should see below stats.
If you see 0 “packets dequeued”, that means there is no Packets received from 
primary to pdump application.
So,  nee to  debug the pdump library what is happening , why primary 
application packets are not send to pdump application. You can try to debugging 
the pdump library and pdump
application.


packets dequeued:

packets transmitted to vdev:

packets freed:
- For the log of pdump
[oran@localhost pdump]$ sudo ./dpdk-pdump --file-prefix wls_1 -- --pdump 
'port=0,queue=*,tx-dev=/home/oran/Music/tx.pcap,rx-dev=/home/oran/Music/rx.pcap'

Also, do you know whether pdump can capture the virtual function packet or not 
? (We bind to vfio-pci)
[Reshma]: I have not tested with VFs ,  I always used PFs.
Best Regards,
Shu-hua, Liao

Pattan, Reshma mailto:reshma.pat...@intel.com>> 於 
2021年11月15日 週一 下午4:58寫道:


From: 廖書華 mailto:sim860...@gmail.com>>
Sent: Monday, November 15, 2021 5:39 AM
To: users@dpdk.org<mailto:users@dpdk.org>
Cc: 林庭安 mailto:lingwan...@gmail.com>>
Subject: Pdump Didn't capture the packet

Dear all,

Currently, I want to use pdump to capture our DPDK application, however for the 
pdump side, unfortunately, didn't capture any packet, also pdump didn't print 
any error. While for our application, it also didn't print any log related to 
pdump.
- Here's the log of pdump
[oran@localhost pdump]$ sudo ./dpdk-pdump --file-prefix wls_1 -- --pdump 
'port=0,queue=*,tx-dev=/home/oran/Music/tx.pcap,rx-dev=/home/oran/Music/rx.pcap'



Primary process is no longer active, exiting...

[Reshma]: From this log it is clear that, primary application is not running.  
Rerun the primary application and in other terminal run the pdump application.

Best Regards,
Shu-hua, Liao


RE: Pdump Didn't capture the packet

2021-11-15 Thread Pattan, Reshma


From: 廖書華 
Sent: Monday, November 15, 2021 5:39 AM
To: users@dpdk.org
Cc: 林庭安 
Subject: Pdump Didn't capture the packet

Dear all,

Currently, I want to use pdump to capture our DPDK application, however for the 
pdump side, unfortunately, didn't capture any packet, also pdump didn't print 
any error. While for our application, it also didn't print any log related to 
pdump.
- Here's the log of pdump
[oran@localhost pdump]$ sudo ./dpdk-pdump --file-prefix wls_1 -- --pdump 
'port=0,queue=*,tx-dev=/home/oran/Music/tx.pcap,rx-dev=/home/oran/Music/rx.pcap'



Primary process is no longer active, exiting...

[Reshma]: From this log it is clear that, primary application is not running.  
Rerun the primary application and in other terminal run the pdump application.

Best Regards,
Shu-hua, Liao


RE: Troubles using pdump to capture the packets

2021-10-15 Thread Pattan, Reshma

From: 廖書華 
Sent: Friday, October 15, 2021 5:16 AM
To: Pattan, Reshma 
Cc: Stephen Hemminger ; users@dpdk.org; 林庭安 

Subject: Re: Troubles using pdump to capture the packets

>>Dear Reshma,

>>Thanks for your kind response ! Unfortunately, it still can't work.


Also, could you please paste me the lbpcap-devel package version on your system.

Thanks,
Reshma

Pattan, Reshma mailto:reshma.pat...@intel.com>> 於 
2021年10月14日 週四 下午5:52寫道:


> -Original Message-
> From: 廖書華 mailto:sim860...@gmail.com>>


> Yes, I already set *CONFIG_RTE_LIBRTE_PMD_PCAP=y *and
> *CONFIG_RTE_LIBRTE_PDUMP=y *in the file "dpdk-
> 19.11/config/common_base"
> then build DPDK.
> Also, in the files "dpdk-19.11/x86_64-native-linuxapp-icc/.config" and "dpdk-
> 19.11/x86_64-native-linuxapp-icc/.config.orig", they also show that
> *CONFIG_RTE_LIBRTE_PMD_PCAP=y *and *CONFIG_RTE_LIBRTE_PDUMP=y.*
>
> It seems that it already enabled pcap PMD of DPDK.
> Do you have other suggestions ?

Hi,

Few options you can double check
1)Make sure your primary application is calling 
rte_pdump_init()/ret_pudmp_uninit() to initialize/uninitialize the pdump 
library.
2)If you are using a shared library build,   double check you are  linking pcap 
pmd properly in primary build as explained in below link
https://www.mail-archive.com/users@dpdk.org/msg05039.html
https://stackoverflow.com/questions/62795017/dpdk-pdump-failed-to-hotplug-add-device
3)If you are passing any pci device using  eal "-w" option to primary,  try to 
pass the same device to secondary also using "-w" option .

If you still see the issue please paste the full primary and secondary 
application run log with command that you are running.
Also what kind of build you are using.

Thanks,
Reshma


RE: Troubles using pdump to capture the packets

2021-10-14 Thread Pattan, Reshma


> -Original Message-
> From: 廖書華 


> Yes, I already set *CONFIG_RTE_LIBRTE_PMD_PCAP=y *and
> *CONFIG_RTE_LIBRTE_PDUMP=y *in the file "dpdk-
> 19.11/config/common_base"
> then build DPDK.
> Also, in the files "dpdk-19.11/x86_64-native-linuxapp-icc/.config" and "dpdk-
> 19.11/x86_64-native-linuxapp-icc/.config.orig", they also show that
> *CONFIG_RTE_LIBRTE_PMD_PCAP=y *and *CONFIG_RTE_LIBRTE_PDUMP=y.*
> 
> It seems that it already enabled pcap PMD of DPDK.
> Do you have other suggestions ?

Hi,

Few options you can double check
1)Make sure your primary application is calling 
rte_pdump_init()/ret_pudmp_uninit() to initialize/uninitialize the pdump 
library.
2)If you are using a shared library build,   double check you are  linking pcap 
pmd properly in primary build as explained in below link
https://www.mail-archive.com/users@dpdk.org/msg05039.html
https://stackoverflow.com/questions/62795017/dpdk-pdump-failed-to-hotplug-add-device
3)If you are passing any pci device using  eal "-w" option to primary,  try to 
pass the same device to secondary also using "-w" option . 

If you still see the issue please paste the full primary and secondary 
application run log with command that you are running.
Also what kind of build you are using.

Thanks,
Reshma
  


Re: [dpdk-users] rte_latency_stats (metrics library)

2019-08-21 Thread Pattan, Reshma


> -Original Message-
> From: Arvind Narayanan [mailto:webguru2...@gmail.com]
> Sent: Saturday, August 3, 2019 11:27 PM
> To: users 
> Cc: Pattan, Reshma 
> Subject: rte_latency_stats (metrics library)
> 
> Hi,
> 
> I am trying to play with latency statistics library (a wrapper around
> rte_metrics lib). Whenever I try to retrieve values using
> rte_latencystats_get(), all the stats are 0.
> Even after rte_latencystats_update() still no effect on the stats.
> 
> Does this library need NIC driver support?
> Any help would be appreciated.
> 

Hi,

Do you have the traffic coming to l2fwd application?  If not you should have 
traffic running from the  traffic generator.


1)If you have traffic already, then can you also cross check by trying to fetch 
these latency stats using rte_metrics apis  instead of latency stats apis. 
(Or) equally you can run the dpdk-proc info secondary application to show you 
the stats (instead of you calling latency stats get and metrics get APIs).

2) Also, In DPDK, testpmd application has been updated to initiate latency 
stats calculation, and to see the stats you can run dpdk-procinfo secondary 
application alongside. 
This is to cross check that traffic is coming to dpdk application and stats are 
been calculated . You can try this second method if you don’t see success with 
l2fwd.

You can refer tespmd and dpdk-procinfo application codes to see how this is 
done.

Thanks,
Reshma


Re: [dpdk-users] dpdk-pdump is not working

2017-06-07 Thread Pattan, Reshma
Hi,

dpdk-pdump is secondary process and it must  be run along with any primary 
process.
The primary process must initialize packet capture framework by calling 
rte_pdump_init() and rt_pdump_uninit() apis, please refer testpmd.c file to see 
how this is done.
Also I suggest you go through the below docs to understand about the usage. Let 
me know if you have any questions.

http://dpdk.org/doc/guides/tools/pdump.html  ==> dpdk-pdump  tool usage 
is explained
 http://dpdk.org/doc/guides/prog_guide/pdump_lib.html  ==> Pdump 
library is explained
   
Thanks,
Reshma

> -Original Message-
> From: users [mailto:users-boun...@dpdk.org] On Behalf Of Heung Sik Choi
> Sent: Friday, June 2, 2017 9:47 AM
> To: users@dpdk.org
> Subject: [dpdk-users] dpdk-pdump is not working
> 
> Hi
> 
> I want to run dpdk-pdump. So, I recompile with option of PCAP and PDUMP.
> Also my machine is dual CPU(Xeon 2630 v2), so I set hugepage with NUMA
> option. the huge page size is 2MB and the number of hugepage is each 8192
> both side.
> 
> when the setting is over, I ran the
> dpdk-pdump(/dpdk/x86_64_native_linuxapp-gcc/build/app/pdump).
> However,  error happens.
> 
> error message is below:
> 
> PANIC in rte_eal_config_attach():
> Cannot open '/var/run/.rte_config' for rte_mem_config
> 6: [./dpdk-pdump() [0x437fc9]]
> 5: [/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf5)
> [0x7f5c419baf45]]
> 4: [./dpdk-pdump(main+0x154) [0x440cd2]]
> 3: [./dpdk-pdump(rte_eal_init+0xd9c) [0x477bec]]
> 2: [./dpdk-pdump(__rte_panic+0xbe) [0x431b20]]
> 1: [./dpdk-pdump(rte_dump_stack+0x1a) [0x47f68a]]
> 
> 
> I also change the dpdk-pdump which is in /dpdk/x86_64_native_linuxapp-
> gcc/app, but same error happens.
> 
> Please let me know if you have any insights.


Re: [dpdk-users] dpdk-pdump: pdump_create_client_socket fails to run along with kni app

2017-04-24 Thread Pattan, Reshma
Hi Gowrishankar,

> PDUMP: failed to send to server:Connection refused,
> pdump_create_client_socket:702
> PDUMP: client request for pdump enable/disable failed
> PDUMP: failed to send to server:Connection refused,
> pdump_create_client_socket:702
> PDUMP: client request for pdump enable/disable failed

Primary application here kni should initialize packet capture framework using 
rte_pdump_init(). And uninitialize rte_pdump_uninit() before application 
terminates.
In DPDK by default only testpmd  has init/uninit changes added. Rest other 
application that wants to use pdump should do these changes explicitly, make 
the build and
rerun the primary and dpdk-pdump applications.

Please refer app/test-pmd/testpmd.c for rte_pdump* code changes and make 
similar change in kni main.c and retest.

Let me know if you stuck.

Thanks,
Reshma


> -Original Message-
> From: users [mailto:users-boun...@dpdk.org] On Behalf Of gowrishankar
> muthukrishnan
> Sent: Friday, April 21, 2017 11:11 AM
> To: users@dpdk.org
> Subject: [dpdk-users] dpdk-pdump: pdump_create_client_socket fails to run
> along with kni app
> 
> Hi,
> I am trying to run dpdk-pdump along with KNI app (in current master ie
> 17.05
> rc2). I find dpdk-pdump crashing as below.
> 
> KNI execution:
> 
> ./examples/kni/build/kni -l 4,5,6,7 --socket-mem 1024 -- -P -p 0x3 --
> config="(0,4,5),(1,6,7)"
> EAL: Detected 32 lcore(s)
> EAL: No free hugepages reported in hugepages-1048576kB
> EAL: Probing VFIO support...
> EAL: VFIO support initialized
> EAL: PCI device :0e:00.0 on NUMA socket 0
> EAL:   probe driver: 8086:10fb net_ixgbe
> EAL:   using IOMMU type 1 (Type 1)
> EAL: Ignore mapping IO port bar(2) addr: 2fc1
> EAL: PCI device :0e:00.1 on NUMA socket 0
> EAL:   probe driver: 8086:10fb net_ixgbe
> EAL: Ignore mapping IO port bar(2) addr: 2fe1
> APP: Initialising port 0 ...
> KNI: pci: 0e:00:00  8086:10fb
> APP: Initialising port 1 ...
> KNI: pci: 0e:00:01  8086:10fb
> 
> Checking link status
> .done
> Port 0 Link Up - speed 1 Mbps - full-duplex Port 1 Link Up - speed 1
> Mbps - full-duplex
> APP: Lcore 5 is writing to port 0
> APP: Lcore 6 is reading from port 1
> APP: Lcore 7 is writing to port 1
> APP: Lcore 4 is reading from port 0
> 
> dpdk pdump execution:
> 
> dpdk-pdump -- --pdump 'port=0,queue=*,rx-dev=/tmp/rx.pcap'
> EAL: Detected 32 lcore(s)
> EAL: Probing VFIO support...
> EAL: VFIO support initialized
> EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in
> the kernel.
> EAL:This may cause issues with mapping memory into secondary processes
> EAL: PCI device :0e:00.0 on NUMA socket 0
> EAL:   probe driver: 8086:10fb net_ixgbe
> EAL: Ignore mapping IO port bar(2) addr: 2fc1
> EAL: PCI device :0e:00.1 on NUMA socket 0
> EAL:   probe driver: 8086:10fb net_ixgbe
> EAL: Ignore mapping IO port bar(2) addr: 2fe1
> PMD: Initializing pmd_pcap for net_pcap_rx_0
> PMD: Creating pcap-backed ethdev on numa socket 4294967295 Port 2 MAC:
> 00 00 00 01 02 03
> PDUMP: failed to send to server:Connection refused,
> pdump_create_client_socket:702
> PDUMP: client request for pdump enable/disable failed
> PDUMP: failed to send to server:Connection refused,
> pdump_create_client_socket:702
> PDUMP: client request for pdump enable/disable failed
> EAL: Error - exiting with code: 1
>Cause: Unknown error -1
> 
> Has this worked before with KNI  or I am doing something not supported ?.
> Before checking further, I just wanted to check with anyone trying/fixing it.
> 
> Thanks,
> Gowrishankar
> 



Re: [dpdk-users] Need your help on pdump

2017-02-08 Thread Pattan, Reshma
Yes.

From: Clarylin L [mailto:clear...@gmail.com]
Sent: Tuesday, February 7, 2017 6:24 PM
To: Pattan, Reshma 
Subject: Re: Need your help on pdump

Hi Reshma,

Thank you for replying!

So if there's a failure to allocate memory for dpdk-pdump, instead of 
allocating more hugepages in the system, we could increase the memory for 
primary process. For example, if we are running testpmd as the primary, we 
could increase --socket-mem so that the hugepage memory for both processes is 
increased. Is that right?

Thanks,

Clarylin

On Tue, Feb 7, 2017 at 5:48 AM, Pattan, Reshma 
mailto:reshma.pat...@intel.com>> wrote:
Hi,

Please see my comments inline.

Thanks,
Reshma

From: Clarylin L [mailto:clear...@gmail.com<mailto:clear...@gmail.com>]
Sent: Friday, February 3, 2017 7:54 PM
To: Pattan, Reshma mailto:reshma.pat...@intel.com>>
Subject: Need your help on pdump

Hi Reshma,

I am currently working on dpdk pdump and got some issues with it. Tried to 
research online but there were not many documents/discussions on it. On the 
mailing list I found you have been helping with someone on pdump, so drop you 
this email trying to seek help.


1. I believe dpdk-pdump would take hugepages. However, number of free 
hugepages does not change at all after dpdk-pdump start running. Is this 
expected?  for example, before starting dpdk-pdump, I have


[Reshma]: dpdk-pdump is a secondary process hence itself will not take any huge 
pages, instead it will be attached to the same huge page memory of the primary 
process.



host# cat /proc/meminfo | grep uge

AnonHugePages:712704 kB

HugePages_Total:1336

HugePages_Free:  661

HugePages_Rsvd:0

HugePages_Surp:0

Hugepagesize:   2048 kB

After dpdk-pdump starts (and it's running fine), the numbers remain the same.



2.   Since Hugepages do not change, it gives me no hint when "cannot 
reserve memory" error comes up on some system. Generally this error is due to 
insufficient hugepages. However, the system shows



[Reshma]: Though huge pages are available the reason for cannot reserve memory 
could be because they are not contiguous huge pages.

Please check the section 2.3.2.1 in 
http://dpdk.org/doc/guides/linux_gsg/sys_reqs.html to allocate contiguous huge 
pages.





host# cat /proc/meminfo | grep uge

AnonHugePages:   1036288 kB

HugePages_Total: 768

HugePages_Free:  376

HugePages_Rsvd:0

HugePages_Surp:0

Hugepagesize:   2048 kB



3. Even when dpdk-pdump is running fine, I got quite a few "PDUMP: User 
mempool: insufficient data_len of mbuf "messages on the server side. I tried to 
increase the mbuf-size for dpdk-pdump and it didn't fix it.





[Reshma]: The mbuf size option that you pass to the dpdk-pdump command line 
option should be equal or greater than the packet size (This is related to the 
internals of design) .

So I suggest you try once again with enough size.





Appreciate your help. Thanks a lot.



Clarylin



Re: [dpdk-users] Need your help on pdump

2017-02-07 Thread Pattan, Reshma
Hi,

Please see my comments inline.

Thanks,
Reshma

From: Clarylin L [mailto:clear...@gmail.com]
Sent: Friday, February 3, 2017 7:54 PM
To: Pattan, Reshma 
Subject: Need your help on pdump

Hi Reshma,

I am currently working on dpdk pdump and got some issues with it. Tried to 
research online but there were not many documents/discussions on it. On the 
mailing list I found you have been helping with someone on pdump, so drop you 
this email trying to seek help.


1. I believe dpdk-pdump would take hugepages. However, number of free 
hugepages does not change at all after dpdk-pdump start running. Is this 
expected?  for example, before starting dpdk-pdump, I have


[Reshma]: dpdk-pdump is a secondary process hence itself will not take any huge 
pages, instead it will be attached to the same huge page memory of the primary 
process.



host# cat /proc/meminfo | grep uge

AnonHugePages:712704 kB

HugePages_Total:1336

HugePages_Free:  661

HugePages_Rsvd:0

HugePages_Surp:0

Hugepagesize:   2048 kB

After dpdk-pdump starts (and it's running fine), the numbers remain the same.



2.   Since Hugepages do not change, it gives me no hint when "cannot 
reserve memory" error comes up on some system. Generally this error is due to 
insufficient hugepages. However, the system shows



[Reshma]: Though huge pages are available the reason for cannot reserve memory 
could be because they are not contiguous huge pages.

Please check the section 2.3.2.1 in 
http://dpdk.org/doc/guides/linux_gsg/sys_reqs.html to allocate contiguous huge 
pages.





host# cat /proc/meminfo | grep uge

AnonHugePages:   1036288 kB

HugePages_Total: 768

HugePages_Free:  376

HugePages_Rsvd:0

HugePages_Surp:0

Hugepagesize:   2048 kB



3. Even when dpdk-pdump is running fine, I got quite a few "PDUMP: User 
mempool: insufficient data_len of mbuf "messages on the server side. I tried to 
increase the mbuf-size for dpdk-pdump and it didn't fix it.





[Reshma]: The mbuf size option that you pass to the dpdk-pdump command line 
option should be equal or greater than the packet size (This is related to the 
internals of design) .

So I suggest you try once again with enough size.





Appreciate your help. Thanks a lot.



Clarylin


[dpdk-users] DPDK packet capture framework doc

2016-11-14 Thread Pattan, Reshma
Hi All,

Usage of DPDK packet capture framework and dpdk-pdump tool is published to 
intel developer zone. Please refer it to understand its usage.

https://software.intel.com/en-us/articles/dpdk-packet-capture-framework

Thanks,
Reshma





[dpdk-users] Capture traffic with DPDK-dump

2016-11-10 Thread Pattan, Reshma
Hi,

Comments below.

Thanks,
Reshma

> -Original Message-
> From: jose suarez [mailto:jsuarezv at ac.upc.edu]
> Sent: Thursday, November 10, 2016 12:32 PM
> To: Pattan, Reshma 
> Cc: users at dpdk.org
> Subject: Re: [dpdk-users] Capture traffic with DPDK-dump
> 
> Hi,
> 
> Thank you very much for your response. I followed your comment about the
> full PCI id and now the PDUMP application is working fine :). It creates the
> pcap file.
> 
> My problem now is that I noticed that in the testpmd app I don't receive any
> packets. I write below the commands that I use to execute both apps:
> 
> # sudo ./x86_64-native-linuxapp-gcc/app/testpmd -c 0x06 -n 4 --proc-type
> primary --socket-mem 1000 --file-prefix pg1 -w :01:00.0 -- -i --port-
> topology=chained
> 
> # sudo ./x86_64-native-linuxapp-gcc/app/dpdk-pdump -c 0xf8 -n 4 --proc-
> type auto --socket-mem 1000 --file-prefix pg2 -w :01:00.0 -- --pdump
> 'device_id=:01:00.0,queue=*,rx-dev=/tmp/file.pcap'
> 
> Before I execute these commands, I ensure that all the hugepages are free
> (sudo rm -R /dev/hugepages/*)
> 
> In this way I split up the hugepages (I have 2048 in total) between both
> processes, as Keith Wiles advised me. Also I don't overlap any core with the
> masks used (0x06 and 0xf8)
> 
> My NIC (Intel 82599ES), which PCI id is :01:00.0, it is connected to a 10G
> link that receives traffic from a mirrored port. I show you the internet 
> device
> settings related to this NIC:
> 
> Network devices using DPDK-compatible driver
> 
> :01:00.0 '82599ES 10-Gigabit SFI/SFP+ Network Connection'
> drv=igb_uio unused=ixgbe
> 
> 
> When I run the testpmd app and check the port stats, I get the following
> output:
> 
> #sudo ./x86_64-native-linuxapp-gcc/app/testpmd -c 0x06 -n 4 --proc-
> type=auto --socket-mem 1000 --file-prefix pg1 -w :01:00.0 -- -i --port-
> topology=chained
> EAL: Detected 8 lcore(s)
> EAL: Auto-detected process type: PRIMARY
> EAL: Probing VFIO support...
> PMD: bnxt_rte_pmd_init() called for (null)
> EAL: PCI device :01:00.0 on NUMA socket 0
> EAL:   probe driver: 8086:10fb rte_ixgbe_pmd
> Interactive-mode selected
> USER1: create a new mbuf pool : n=155456,
> size=2176,
> socket=0
> Configuring Port 0 (socket 0)
> Port 0: XX:XX:XX:XX:XX:XX
> Checking link statuses...
> Port 0 Link Up - speed 1 Mbps - full-duplex Done
> testpmd> show port stats 0


After testpmd comes to the prompt, you need to execute command "start". This 
will start traffic forwarding.

> NIC statistics for port 0
> 
>RX-packets: 0  RX-missed: 0  RX-bytes:  0
>RX-errors: 0
>RX-nombuf:  0
>TX-packets: 0  TX-errors: 0  TX-bytes:  0
> 
>Throughput (since last show)
>Rx-pps:0
>Tx-pps:0
> 
> 
> 
> It doesn't receive any packet. Did I missed any step in the configuration of
> the testpmd app?

I am wondering , you should see all packets hitting Rx-missed. 
So I suggest just stop everything. Unbind port back to Linux. Then check if the 
port is receiving packets from other end using tcpdump. 
If not then you may need to debug the issue. 

After everything is fine, bind back the port to dpdk, run testpmd and see if 
you could receive packets or not. 
If you are seeing packets against "Rx-missed", then run start command in 
testpmd prompt to start packet forwarding. After that you will be able to
See the packets in the capture file.

Thanks,
Reshma



[dpdk-users] PDUMP: failed to send to server:Connection refused

2016-11-10 Thread Pattan, Reshma
Hi,

I really apologize for not noticing this mail.

comments are below.

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of Sandeep
> Rayapudi
> Sent: Thursday, August 25, 2016 5:01 PM
> To: users at dpdk.org
> Subject: [dpdk-users] PDUMP: failed to send to server:Connection refused
> 
> Hi all,
> 
> I'm trying the following scenario and PDUMP doesn't start up even though
> I'm running traffic generator. My idea is to generate traffic from one host
> and dump on another host.
> 
> 1. Downloaded DPDK latest version on two hosts and compiled DPDK with
> CONFIG_RTE_LIBRTE_PMD_PCAP=y 2. On both of these hosts, I made one of
> the NIC as DPDK enabled 3. On host 1, I did:
> ./app/app/x86_64-native-linuxapp-gcc/pktgen -c 0x1f -n 3 -- -P -m "[1:3].0"
> The packet generator starts and prints:
> 
>Copyright (c) <2010-2016>, Intel Corporation. All rights reserved.
>Pktgen created by: Keith Wiles -- >>> Powered by Intel? DPDK <<<
> 
> Lua 5.3.2  Copyright (C) 1994-2015 Lua.org, PUC-Rio
> >>> Packet Burst 32, RX Desc 512, TX Desc 512, mbufs/port 4096, mbuf
> >>> cache
> 512
> 
> === port to lcore mapping table (# lcores 5) ===
>lcore: 0 1 2 3 4
> port   0:  D: T  1: 0  0: 0  0: 1  0: 0 =  1: 1
> Total   :  0: 0  1: 0  0: 0  0: 1  0: 0
> Display and Timer on lcore 0, rx:tx counts per port/lcore
> 
> Configuring 2 ports, MBUF Size 1920, MBUF Cache Size 512
> Lcore:
> 1, RX-Only
> RX( 1): ( 0: 0)
> 3, TX-Only
> TX( 1): ( 0: 0)
> 
> Port :
> 0, nb_lcores  2, private 0x8ac490, lcores:  1  3
> 
> 
> 
> ** Dev Info (rte_ixgbe_pmd:0) **
>max_vfs:   0 min_rx_bufsize:1024 max_rx_pktlen : 15872
> max_rx_queues : 128 max_tx_queues:  64
>max_mac_addrs  : 127 max_hash_mac_addrs:4096 max_vmdq_pools:64
>rx_offload_capa:  31 tx_offload_capa   :  63 reta_size :   128
> flow_type_rss_offloads:00038d34
>vmdq_queue_base:   0 vmdq_queue_num: 128 vmdq_pool_base: 0
> ** RX Conf **
>pthreash   :   8 hthresh  :   8 wthresh: 0
>Free Thresh:  32 Drop Enable  :   0 Deferred Start : 0
> ** TX Conf **
>pthreash   :  32 hthresh  :   0 wthresh: 0
>Free Thresh:  32 RS Thresh:  32 Deferred Start : 0 TXQ
> Flags:0f01
> 
> Initialize Port 0 -- TxQ 1, RxQ 1,  Src MAC 00:11:0a:67:d7:dc
> Create: Default RX  0:0  - Memory used (MBUFs 4096 x (size 1920 + Hdr
> 128)) + 192 =   8193 KB headroom 128 2176
>   Set RX queue stats mapping pid 0, q 0, lcore 1
> 
> 
> Create: Default TX  0:0  - Memory used (MBUFs 4096 x (size 1920 + Hdr
> 128)) + 192 =   8193 KB headroom 128 2176
> Create: Range TX0:0  - Memory used (MBUFs 4096 x (size 1920 + Hdr
> 128)) + 192 =   8193 KB headroom 128 2176
> Create: Sequence TX 0:0  - Memory used (MBUFs 4096 x (size 1920 + Hdr
> 128)) + 192 =   8193 KB headroom 128 2176
> Create: Special TX  0:0  - Memory used (MBUFs   64 x (size 1920 + Hdr
> 128)) + 192 =129 KB headroom 128 2176
> 
>Port 
> memory used =  32897 KB
>   Total 
> memory used =  32897 KB
> Port  0: Link Up - speed 1 Mbps - full-duplex  mode>
> 
> 
> === Display processing on lcore 0
> WARNING: Nothing to do on lcore 2: exiting
> WARNING: Nothing to do on lcore 4: exiting
>   RX processing lcore:   1 rx:  1 tx:  0
>   TX processing lcore:   3 rx:  0 tx:  1
> 
> 
> 
> 
> 
> 
> / Ports 0-1 of 2 Copyright (c) <2010-2016>, Intel Corporation
>   Flags:Port  :   P--:0
> Link State:TotalRate
> Pkts/s Max/Rx : 0/0   0/0
>Max/Tx : 0/0   0/0
> MBits/s Rx/Tx : 0/0   0/0
> Broadcast :   0
> Multicast :   0
>   64 Bytes:   0
>   65-127  :   0
>   128-255 :   0
>   256-511 :   0
>   512-1023:   0
>   1024-1518   :   0
> Runts/Jumbos  : 0/0
> Errors Rx/Tx  : 0/0
> Total Rx Pkts :   0
>   Tx Pkts :   0
>   Rx MBs  :   0
>   Tx MBs  :   0
> ARP/ICMP Pkts : 0/0
>   :
> Pattern Type  : abcd...
> Tx Count/% Rate   :  Forever / 100%
> PktSize/Tx Burst  :   64 /   32
> Src/Dest Port : 1234 / 5678
> Pkt Type:VLAN ID  : IPv4 / TCP:0001
> Dst  IP Address   : 192.168.1.1
> Src  IP Address   :  192.168.0.1/24
> Dst MAC Address   :   00:00:00:00:00:00
> Src MAC Address   :   00:11:0a:67:d7:

[dpdk-users] Capture traffic with DPDK-dump

2016-11-10 Thread Pattan, Reshma
Hi,

Comments below.

Thanks,
Reshma


> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of jose suarez
> Sent: Monday, November 7, 2016 5:50 PM
> To: users at dpdk.org
> Subject: [dpdk-users] Capture traffic with DPDK-dump
> 
> Hello everybody!
> 
> I am new in DPDK. I'm trying simply to capture traffic from a 10G physical
> NIC. I installed the DPDK from source files and activated the following
> modules in common-base file:
> 
> CONFIG_RTE_LIBRTE_PMD_PCAP=y
> 
> CONFIG_RTE_LIBRTE_PDUMP=y
> 
> CONFIG_RTE_PORT_PCAP=y
> 
> Then I built the distribution using the dpdk-setup.h script. Also I add
> hugepages and check they are configured successfully:
> 
> AnonHugePages:  4096 kB
> HugePages_Total:2048
> HugePages_Free:0
> HugePages_Rsvd:0
> HugePages_Surp:0
> Hugepagesize:   2048 kB
> 
> To capture the traffic I guess I can use the dpdk-pdump application, but I
> don't know how to use it. First of all, does it work if I bind the interfaces
> using the uio_pci_generic drive? I guess that if I capture the traffic using 
> the
> linux kernel driver (ixgbe) I will loose a lot of packets.
> 
> To bind the NIC I write this command:
> 
> sudo ./tools/dpdk-devbind.py --bind=uio_pci_generic eth0
> 
> 
> When I check the interfaces I can see that the NIC was binded successfully.
> Also I checked that mi NIC is compatible with DPDK (Intel
> 8599)
> 
> Network devices using DPDK-compatible driver
> 
> :01:00.0 '82599ES 10-Gigabit SFI/SFP+ Network Connection'
> drv=uio_pci_generic unused=ixgbe,vfio-pci
> 
> 
> To capture packets, I read in the mailing list that it is necessary to run the
> testpmd application and then dpdk-pdump using different cores.
> So I used the following commands:
> 
> sudo ./x86_64-native-linuxapp-gcc/app/testpmd -c 0x6 -n 4 -- -i
> 
> sudo ./x86_64-native-linuxapp-gcc/app/dpdk-pdump -c 0xff -n 2 -- --pdump
> 'device_id=01:00.0,queue=*,rx-dev=/tmp/file.pcap'

1)Please pass on the full PCI id, i.e ":01:00.0" in the command instead of 
"01:00.0".
In latest DPDK 16.11 code  full PCI id is used by eal layer to identify the 
device. 

2)Also note that you should not use same core mask for both primary and 
secondary processes in multi process context.
ex: -c0x6 for testpmd and -c0x2 for dpdk-pdump can be used. 

Please let me know how you are proceeding.


Thanks,
Reshma


[dpdk-users] DPDPK-PDUMP not creating rx file

2016-11-02 Thread Pattan, Reshma
Hi,

At lease I am not seeing this issue on Ubuntu.

1)Line 634 is,  for (i = 0; i < num_tuples; i++) right?
2)Can you send me the file with debug prints and startup logs of dpdk-pdump 
tool with debug prints, so that I can map file printfs and logs.

Note:
Also, don?t use same cores for primary process(testpmd) and secondary 
process(dpdk-pdump) . In multi process different cores should be used for the 
processes.
In the commands that you have provided I see 0xff is used for testpmd and 
dpdk-pdump. Please use different cores.
Ex:
sudo ./x86_64-native-linuxapp-gcc/app/testpmd -c 0x6 -n 4 -- -i
sudo ./app/pdump/dpdk-pdump -c 0x2 -n 2 -- --pdump 
'port=0,queue=*,rx-dev=/tmp/rx-1-file.pcap'

Thanks,
Reshma

From: shokoofeh nobahari [mailto:sh.nobahar...@gmail.com]
Sent: Wednesday, November 2, 2016 10:12 AM
To: Pattan, Reshma 
Subject: Re: DPDPK-PDUMP not creating rx file

Hi Reshma
I edited the main.c file and I added printf() before every if , so I find out 
that after the if , in line 634 , it stops

for (i = 0; i < num_tuples; i++) {
pt = &pdump_t[i];
snprintf(mempool_name, SIZE, MP_NAME, i);
mbuf_pool = rte_mempool_lookup(mempool_name);
if (mbuf_pool == NULL) {
/* create mempool */
mbuf_pool = rte_pktmbuf_pool_create(mempool_name,
pt->total_num_mbufs,
MBUF_POOL_CACHE_SIZE, 0,
pt->mbuf_data_size,
rte_socket_id());
if (mbuf_pool == NULL) {
cleanup_rings();
rte_exit(EXIT_FAILURE,
"Mempool creation failed: %s\n",
rte_strerror(rte_errno));
}
there was no error or log just stops there
also the output of other requested commands:
#grep CONFIG_RTE_LIBRTE_PMD_PCAP config/common_base

CONFIG_RTE_LIBRTE_PMD_PCAP=y



#rpm -qa | grep pcap
there was no output for this command
thank you very much for your time Reshma


On Tue, Nov 1, 2016 at 6:16 PM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi,

My replies inline.

Thanks,
Reshma

From: shokoofeh nobahari [mailto:sh.nobahari65 at 
gmail.com<mailto:sh.nobahar...@gmail.com>]
Sent: Sunday, October 30, 2016 7:11 AM
To: Pattan, Reshma mailto:reshma.pattan at 
intel.com>>
Subject: Re: DPDPK-PDUMP not creating rx file

Hi again Reshma
I worked on testpmd and below is the output of testpmd command in dpdk-setup.sh 
script (number 28 in the list)  :

Option: 28


  Enter hex bitmask of cores to execute testpmd app on
  Example: to execute app on cores 0 to 7, enter 0xff
bitmask: 0xff
Launching app
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL:   no supported IOMMU extensions found!
EAL: VFIO support could not be initialized
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :0e:00.0 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
EAL: PCI device :0e:00.1 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
Interactive-mode selected
USER1: create a new mbuf pool : n=203456, size=2176, 
socket=0
Configuring Port 0 (socket 0)
Port 0: 00:1F:29:5A:65:40
Configuring Port 1 (socket 0)
Port 1: 00:1F:29:5A:65:41
Checking link statuses...
Port 0 Link Up - speed 1000 Mbps - full-duplex
Port 1 Link Down
Done
testpmd> start
io packet forwarding - ports=2 - cores=1 - streams=2 - NUMA support disabled, 
MP over anonymous pages disabled
Logical Core 1 (socket 1) forwards packets on 2 streams:
  RX P=0/Q=0 (socket 0) -> TX P=1/Q=0 (socket 0) peer=02:00:00:00:00:01
  RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00

  io packet forwarding - CRC stripping disabled - packets/burst=32
  nb forwarding cores=1 - nb forwarding ports=2
  RX queues=1 - RX desc=128 - RX free threshold=0
  RX threshold registers: pthresh=0 hthresh=0 wthresh=0
  TX queues=1 - TX desc=512 - TX free threshold=0
  TX threshold registers: pthresh=0 hthresh=0 wthresh=0
  TX RS bit threshold=0 - TXQ flags=0x0
testpmd> stop
Telling cores to stop...
Waiting for lcores to finish...

  -- Forward statistics for port 0  --
  RX-packets: 131RX-dropped: 0 RX-total: 131
  TX-packets: 0  TX-dropped: 0 TX-total: 0
  

  -- Forward statistics for port 1  --
  RX-packets: 0  RX-dropped: 0 RX-total: 0
  TX-packets: 0  TX-dropped: 0 TX-total: 0
  

  +++ Accumulated forward statistics for all ports+++
  RX-packets: 131RX-dropped: 0 RX-total: 131
  TX-packets: 0  TX-dropped: 0 TX-total: 0
  

Done.

[dpdk-users] DPDPK-PDUMP not creating rx file

2016-11-01 Thread Pattan, Reshma
Hi,

My replies inline.

Thanks,
Reshma

From: shokoofeh nobahari [mailto:sh.nobahar...@gmail.com]
Sent: Sunday, October 30, 2016 7:11 AM
To: Pattan, Reshma 
Subject: Re: DPDPK-PDUMP not creating rx file

Hi again Reshma
I worked on testpmd and below is the output of testpmd command in dpdk-setup.sh 
script (number 28 in the list)  :

Option: 28


  Enter hex bitmask of cores to execute testpmd app on
  Example: to execute app on cores 0 to 7, enter 0xff
bitmask: 0xff
Launching app
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL:   no supported IOMMU extensions found!
EAL: VFIO support could not be initialized
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :0e:00.0 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
EAL: PCI device :0e:00.1 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
Interactive-mode selected
USER1: create a new mbuf pool : n=203456, size=2176, 
socket=0
Configuring Port 0 (socket 0)
Port 0: 00:1F:29:5A:65:40
Configuring Port 1 (socket 0)
Port 1: 00:1F:29:5A:65:41
Checking link statuses...
Port 0 Link Up - speed 1000 Mbps - full-duplex
Port 1 Link Down
Done
testpmd> start
io packet forwarding - ports=2 - cores=1 - streams=2 - NUMA support disabled, 
MP over anonymous pages disabled
Logical Core 1 (socket 1) forwards packets on 2 streams:
  RX P=0/Q=0 (socket 0) -> TX P=1/Q=0 (socket 0) peer=02:00:00:00:00:01
  RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00

  io packet forwarding - CRC stripping disabled - packets/burst=32
  nb forwarding cores=1 - nb forwarding ports=2
  RX queues=1 - RX desc=128 - RX free threshold=0
  RX threshold registers: pthresh=0 hthresh=0 wthresh=0
  TX queues=1 - TX desc=512 - TX free threshold=0
  TX threshold registers: pthresh=0 hthresh=0 wthresh=0
  TX RS bit threshold=0 - TXQ flags=0x0
testpmd> stop
Telling cores to stop...
Waiting for lcores to finish...

  -- Forward statistics for port 0  --
  RX-packets: 131RX-dropped: 0 RX-total: 131
  TX-packets: 0  TX-dropped: 0 TX-total: 0
  

  -- Forward statistics for port 1  --
  RX-packets: 0  RX-dropped: 0 RX-total: 0
  TX-packets: 0  TX-dropped: 0 TX-total: 0
  

  +++ Accumulated forward statistics for all ports+++
  RX-packets: 131RX-dropped: 0 RX-total: 131
  TX-packets: 0  TX-dropped: 0 TX-total: 0
  

Done.

and here is the output od dpdk-pdump command , it is stiil ruunin gbut not 
creating rx.pcap file

./dpdk-pdump -c 0xff -n2 -- pdump 'port=0,queue=*,rx-dev=/tmp/rx.pcap'

EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL:   cannot connect to primary process!
EAL: VFIO support could not be initialized
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL:This may cause issues with mapping memory into secondary processes
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :0e:00.0 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
EAL: PCI device :0e:00.1 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
[Reshma 1]:
After above logs you should be seeing  logs similar to below ones.

PMD: Initializing pmd_pcap for eth_pcap_rx_0
PMD: Creating pcap-backed ethdev on numa socket 0
Port 2 MAC: 00 00 00 01 02 03

Since you are not seeing, I guess dpdk-pdump tool  might have got stuck in the 
code somewhere.
Can you just add some  debug prints  after the below if condition in the file 
app/pdump/main.c, there are  3 such if conditions, so add prints at all 3 
places.
Compile the dpdk-pdump again , run and give me the startup logs.

if (rte_eth_dev_attach(vdev_args,
&portid) < 0) {
cleanup_rings();
rte_exit(EXIT_FAILURE,
"vdev creation failed:"
"%s:%d\n", __func__, __LINE__);
}

[Reshma 2]:
Can you provide the output of ?rpm -qa | grep pcap?

[Reshma 3]:
Can you give the output of ?grep CONFIG_RTE_LIBRTE_PMD_PCAP config/common_base?

Thanks,
Reshma

I have no idea what is the problem!



On Sat, Oct 29, 2016 at 4:33 PM, shokoofeh nobahari mailto:sh.nobahari65 at gmail.com>> wrote:
Hi Reshma
I re installed everything from Ubuntu OS to dpdk and here is the output of 
testpmd command:

# ./testpmd -c 3 -n 4 -- portmask=0x01 --port-topology=chained
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL:   no supported IOMMU extensions found!
EAL: VFIO support could not be initialized
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :0e:00.0 on NUMA socket -1
EAL:   probe driver: 8086:105e rte_em_pmd
EAL: PCI device :0

[dpdk-users] DPDPK-PDUMP not creating rx file

2016-10-25 Thread Pattan, Reshma
Hi,

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of shokoofeh nobahari
> Sent: Tuesday, October 25, 2016 12:46 PM
> To: users at dpdk.org
> Subject: [dpdk-users] DPDPK-PDUMP not creating rx file
> 
> Dear all
> I am executing DPDK 16.07 on a physical ubuntu server with 2 Intel NIC and I
> need to capture the traffic to pcap files so I am using pdump API.
> I also set CONFIG_RTE_LIBRTE_PMD_PCAP=y in common-base file in config
> directory of DPDK and recompile the build.
> dpdk-pdump is running and working but it is not creating the rx.pcap file .

I assume you are running testpmd first and then dpdk-pdump tool, is that 
correct?
Also I see you are using rx-dev as rx-1-file.pcap but not rx.pcap file. So you 
should look for file 
rx-1-file.pcap but not rx.pcap, or is that a typo in your sentence?

> My command is like below:
> 
> ./dpdk-pdump -c 3 -n 2 -- --pdump 'device_id=0e:00.0,queue=*,rx- dev=/tmp/rx-
> 1-file.pcap'
> 
> 
> I will be very grateful if you can help me with this situation !
> thank you all


[dpdk-users] pdump help

2016-07-25 Thread Pattan, Reshma
Hi Nishant,

Comments inline

Thanks,
Reshma
From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Monday, July 25, 2016 8:31 PM
To: Pattan, Reshma 
Cc: users at dpdk.org
Subject: Re: pdump help

Hi Reshma,
1. Not sure what exactly is the issue behind this. But as of now i did 2 
things, in place of running setup.sh, i tried to give make command, with 
DESTDIR.
Now i got exe.
So if i execute the dpdk_pdump from this folder(destination directory that i 
gave at the time of building DPDK), it is working fine.
But if i go in ./dpdk/app/pdump, build app here and then try to run it is not 
working.
Ok, I will check this issue and fix if it is a bug. That is good that you could 
run from DESTDIR, I always ran from DESTDIR.
2. Even their is no  packet to capture, it showing error "insufficient data_len 
of mbuf"
this is how i run and end pdump execution.
"
The mbuf-size that you pass to dpdk_pdump command should be same or greater 
than the mbuf size that was used for mempool creation for the Rx packets inside 
the primary application.
Ex: in L3fwd, the size used is RTE_MBUF_DEFAULT_BUF_SIZE.
rte_pktmbuf_pool_create(s, nb_mbuf, MEMPOOL_CACHE_SIZE, 0, 
RTE_MBUF_DEFAULT_BUF_SIZE, socketid);

If you know that value you can pass it on, else I suggest don?t pass any value, 
then dpdk_pdump will use default mbuf size internally i.e. 
(RTE_MBUF_DEFAULT_BUF_SIZE).
Here you are using mbuf-size 20 which is far less than the what l3fwd is using, 
hence pdump library will throw this error in such cases.

Try suggested points and let me know if you see any more issues.

root at ubuntu:/home/oneweb/dpdk/install/bin# ./dpdk_pdump --file-prefix l3f -- 
--pdump 
'port=0,queue=*,rx-dev=/tmp/rx-file.pcap,tx-dev=/tmp/tx-file.pcap,ring-size=1024,mbuf-size=20,total-num-mbufs=1025'
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: VFIO support initialized
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL: This may cause issues with mapping memory into secondary processes
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL: probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL: probe driver: 8086:15ad rte_ixgbe_pmd
PMD: eth_ixgbe_dev_init(): No TX queues configured yet. Using default TX 
function.
EAL: PCI device :05:00.0 on NUMA socket 0
EAL: probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL: probe driver: 8086:1521 rte_igb_pmd
PMD: Initializing pmd_pcap for eth_pcap_rx_0
PMD: Creating pcap-backed ethdev on numa socket 0
Port 2 MAC: 00 00 00 01 02 03
PMD: Initializing pmd_pcap for eth_pcap_tx_0
PMD: Creating pcap-backed ethdev on numa socket 0
Port 3 MAC: 00 00 00 01 02 03
^C

Signal 2 received, preparing to exit...
# PDUMP DEBUG STATS #
-packets dequeued: 0
-packets transmitted to vdev: 0
-packets freed: 0
"
Here is what i get on l3fwd side..
"
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf
PDUMP: User mempool: insufficient data_len of mbuf

"

Atlast it seems to be working, thanks for the much needed help.
Rgds,
Nishant


On Mon, Jul 25, 2016 at 12:21 PM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi Nishant,

The possible reasons for below error are


1)  Either  below falg is set to ?n? in config/common_base file, please set 
it to ?y? and compile again.

If this falg is not in the config/comman_base for you, just check other config 
files where this flag is there and make necessary change.

# Compile software PMD backed by PCAP files

#

CONFIG_RTE_LIBRTE_PMD_PCAP=n



2)  (Or) you might be having dpdk code which don?t have below fix. If you 
don?t have this fix, please add this fix , compile and check again.

http://dpdk.org/dev/patchwork/patch/14709/

diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c

index b341f93..7125823 100644

--- a/drivers/net/pcap/rte_eth_pcap.c

+++ b/drivers/net/pcap/rte_eth_pcap.c

@@ -1090,6 +1090,6 @@  static struct rte_driver pmd_pcap_drv = {

.uninit = rte_pmd_pcap_devuninit,

 };



-PMD_REGISTER_DRIVER(pmd_pcap_drv, pcap);

-DRIVER_REGISTER_PARAM_STRING(pcap, "rx_pcap= tx_pcap= "

+PMD_REGISTER_DRIVER(pmd_pcap_drv, eth_pcap);

+DRIVER_REGISTER_PARAM_STRING(eth_pcap, "rx_pcap= tx_pcap= "


Please 

[dpdk-users] pdump help

2016-07-25 Thread Pattan, Reshma
Hi Nishant,

The possible reasons for below error are


1)  Either  below falg is set to ?n? in config/common_base file, please set 
it to ?y? and compile again.

If this falg is not in the config/comman_base for you, just check other config 
files where this flag is there and make necessary change.

# Compile software PMD backed by PCAP files

#

CONFIG_RTE_LIBRTE_PMD_PCAP=n



2)  (Or) you might be having dpdk code which don?t have below fix. If you 
don?t have this fix, please add this fix , compile and check again.

http://dpdk.org/dev/patchwork/patch/14709/

diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c

index b341f93..7125823 100644

--- a/drivers/net/pcap/rte_eth_pcap.c

+++ b/drivers/net/pcap/rte_eth_pcap.c

@@ -1090,6 +1090,6 @@  static struct rte_driver pmd_pcap_drv = {

.uninit = rte_pmd_pcap_devuninit,

 };



-PMD_REGISTER_DRIVER(pmd_pcap_drv, pcap);

-DRIVER_REGISTER_PARAM_STRING(pcap, "rx_pcap= tx_pcap= "

+PMD_REGISTER_DRIVER(pmd_pcap_drv, eth_pcap);

+DRIVER_REGISTER_PARAM_STRING(eth_pcap, "rx_pcap= tx_pcap= "


Please check these 2 items and make the necessary changes and let me know how 
do you proceed.

Thanks,
Reshma

From: Pattan, Reshma
Sent: Monday, July 25, 2016 5:01 PM
To: 'Nishant Verma' 
Cc: users at dpdk.org
Subject: RE: pdump help

Hi,

Can you paste me file config/common_base content output

Thanks,
Reshma

From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Monday, July 25, 2016 4:58 PM
To: Pattan, Reshma mailto:reshma.pattan at 
intel.com>>
Cc: users at dpdk.org<mailto:users at dpdk.org>
Subject: Re: pdump help

Hi Reshma,
Error cause is still same, but i think their is some progress what i see in 
error log as of now.
Don't know what exact ican share that will help you in debug the issue, so as 
of now sharing HugePage output, l3fwd log & pdump error log.
If you need anything else, please let me know.

Option: 29

AnonHugePages:  2048 kB
HugePages_Total:8192
HugePages_Free: 7680
HugePages_Rsvd:0
HugePages_Surp:0
Hugepagesize:   2048 kB




--

root at ubuntu:/home/oneweb/dpdk/examples/l3fwd/build/app# ./l3fwd -c 606 -n 4 
--proc-type=primary  --socket-mem=1024 --file-prefix l3f -- -p 0x1 
--config="(0,0,1),(0,1,2)"
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: VFIO support initialized
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
L3FWD: LPM or EM none selected, default LPM on
Initializing port 0 ... Creating queues: nb_rxq=2 nb_txq=4...  
Address:0C:C4:7A:73:EF:14, Destination:02:00:00:00:00:00, Allocated mbuf pool 
on socket 0
LPM: Adding route 0x01010100 / 24 (0)
LPM: Adding route IPV6 / 48 (0)
===Initialized PDUMP
txq=1,0,0 txq=2,1,0 txq=9,2,0 txq=10,3,0

Skipping disabled port 1

Initializing rx queues on lcore 1 ... rxq=0,0,0
Initializing rx queues on lcore 2 ... rxq=0,1,0
Initializing rx queues on lcore 9 ...
Initializing rx queues on lcore 10 ...


Checking link status..done
Port 0 Link Up - speed 1 Mbps - full-duplex
L3FWD: entering main loop on lcore 2
L3FWD:  -- lcoreid=2 portid=0 rxqueueid=1
L3FWD: lcore 9 has nothing to do
L3FWD: entering main loop on lcore 1
L3FWD:  -- lcoreid=1 portid=0 rxqueueid=0
L3FWD: lcore 10 has nothing to do

---



root at ubuntu:/home/oneweb/dpdk/app/pdump# ./dpdk_pdump --file-prefix l3f  -- 
--pdump 
'port=0,queue=*,rx-dev=/tmp/rx-file.pcap,tx-dev=/tmp/tx-file.pcap,ring-size=1024,mbuf-size=20,total-num-mbufs=1025'
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: VFIO support initialized
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL:This may cause issues with mapping memory into secondary processes
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
PMD: eth_ixgbe_dev_init(): No TX queues configured yet. Using default TX 
function.
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: no driver found for eth_pcap_rx_0
EAL: Driver, cannot attach the device
EAL: Error - exiting with code: 1
  Cause: vdev creation failed:create_mp_ring_vdev:669
rgds,
Nishant

On Mon, Jul 25, 2016 at 4:57 AM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi Nishant,

1)Since you are us

[dpdk-users] pdump help

2016-07-25 Thread Pattan, Reshma
Hi,

Can you paste me file config/common_base content output

Thanks,
Reshma

From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Monday, July 25, 2016 4:58 PM
To: Pattan, Reshma 
Cc: users at dpdk.org
Subject: Re: pdump help

Hi Reshma,
Error cause is still same, but i think their is some progress what i see in 
error log as of now.
Don't know what exact ican share that will help you in debug the issue, so as 
of now sharing HugePage output, l3fwd log & pdump error log.
If you need anything else, please let me know.

Option: 29

AnonHugePages:  2048 kB
HugePages_Total:8192
HugePages_Free: 7680
HugePages_Rsvd:0
HugePages_Surp:0
Hugepagesize:   2048 kB




--

root at ubuntu:/home/oneweb/dpdk/examples/l3fwd/build/app# ./l3fwd -c 606 -n 4 
--proc-type=primary  --socket-mem=1024 --file-prefix l3f -- -p 0x1 
--config="(0,0,1),(0,1,2)"
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: VFIO support initialized
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
L3FWD: LPM or EM none selected, default LPM on
Initializing port 0 ... Creating queues: nb_rxq=2 nb_txq=4...  
Address:0C:C4:7A:73:EF:14, Destination:02:00:00:00:00:00, Allocated mbuf pool 
on socket 0
LPM: Adding route 0x01010100 / 24 (0)
LPM: Adding route IPV6 / 48 (0)
===Initialized PDUMP
txq=1,0,0 txq=2,1,0 txq=9,2,0 txq=10,3,0

Skipping disabled port 1

Initializing rx queues on lcore 1 ... rxq=0,0,0
Initializing rx queues on lcore 2 ... rxq=0,1,0
Initializing rx queues on lcore 9 ...
Initializing rx queues on lcore 10 ...


Checking link status..done
Port 0 Link Up - speed 1 Mbps - full-duplex
L3FWD: entering main loop on lcore 2
L3FWD:  -- lcoreid=2 portid=0 rxqueueid=1
L3FWD: lcore 9 has nothing to do
L3FWD: entering main loop on lcore 1
L3FWD:  -- lcoreid=1 portid=0 rxqueueid=0
L3FWD: lcore 10 has nothing to do

---



root at ubuntu:/home/oneweb/dpdk/app/pdump# ./dpdk_pdump --file-prefix l3f  -- 
--pdump 
'port=0,queue=*,rx-dev=/tmp/rx-file.pcap,tx-dev=/tmp/tx-file.pcap,ring-size=1024,mbuf-size=20,total-num-mbufs=1025'
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: VFIO support initialized
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL:This may cause issues with mapping memory into secondary processes
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
PMD: eth_ixgbe_dev_init(): No TX queues configured yet. Using default TX 
function.
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: no driver found for eth_pcap_rx_0
EAL: Driver, cannot attach the device
EAL: Error - exiting with code: 1
  Cause: vdev creation failed:create_mp_ring_vdev:669

rgds,
Nishant

On Mon, Jul 25, 2016 at 4:57 AM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi Nishant,

1)Since you are using  --file-prefix l3f in l3fwd command, you need to use same 
file prefix in dpdk_pdump command also. This solves below reported issue.

2)And also make sure l3fwd application initializes packet capture framework by 
calling rte_pdump_init () api from its main().
 Also should  call uninitialize  api rte_pdump_uninit() before exiting l3fwd 
application. Please refer app/test-pmd/testpmd.c file to see how these apis are 
used.

Ex:
int
main(int argc, char** argv)
{
int  diag;
uint8_t port_id;

signal(SIGINT, signal_handler);
signal(SIGTERM, signal_handler);

diag = rte_eal_init(argc, argv);
if (diag < 0)
rte_panic("Cannot init EAL\n");
#ifdef RTE_LIBRTE_PDUMP
/* initialize packet capture framework */
rte_pdump_init(NULL);

static void
signal_handler(int signum)
{
if (signum == SIGINT || signum == SIGTERM) {
printf("\nSignal %d received, preparing to exit...\n",
signum);
#ifdef RTE_LIBRTE_PDUMP
/* uninitialize packet capture framework */
rte_pdump_uninit();
#endif

3)As of now initializing and un initializing of the packet capture framework is 
done only in testpmd, for other applications this is not done. We left users to 
do this for now.


Please feel free to ping me if you see some more issues.

Thanks,
Reshma
Fr

[dpdk-users] pdump help

2016-07-25 Thread Pattan, Reshma
Hi Nishant,

1)Since you are using  --file-prefix l3f in l3fwd command, you need to use same 
file prefix in dpdk_pdump command also. This solves below reported issue.

2)And also make sure l3fwd application initializes packet capture framework by 
calling rte_pdump_init () api from its main().
 Also should  call uninitialize  api rte_pdump_uninit() before exiting l3fwd 
application. Please refer app/test-pmd/testpmd.c file to see how these apis are 
used.

Ex:
int
main(int argc, char** argv)
{
int  diag;
uint8_t port_id;

signal(SIGINT, signal_handler);
signal(SIGTERM, signal_handler);

diag = rte_eal_init(argc, argv);
if (diag < 0)
rte_panic("Cannot init EAL\n");
#ifdef RTE_LIBRTE_PDUMP
/* initialize packet capture framework */
rte_pdump_init(NULL);

static void
signal_handler(int signum)
{
if (signum == SIGINT || signum == SIGTERM) {
printf("\nSignal %d received, preparing to exit...\n",
signum);
#ifdef RTE_LIBRTE_PDUMP
/* uninitialize packet capture framework */
rte_pdump_uninit();
#endif

3)As of now initializing and un initializing of the packet capture framework is 
done only in testpmd, for other applications this is not done. We left users to 
do this for now.


Please feel free to ping me if you see some more issues.

Thanks,
Reshma
From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Friday, July 22, 2016 10:42 PM
To: Pattan, Reshma 
Cc: users at dpdk.org
Subject: Re: pdump help

Hi,
Something is still creating the problem. just can't figure out.
Here is the scenario
Just inserted IGB UIO module, attached one 10G NIC to DPDK &
4096 hugepage.

---
trying to run l3fwd as primary and pducp as secondary  to capture packet dump.
Earlier dpdk_pdump is crashing on either create_mp_ring_vdev:649 or 
create_mp_ring_vdev:669.
Now i changed some parameters of pdump and l3fwd, change hugepages to 8192 and 
tried to run like this..
./l3fwd -c 606 -n 4 --proc-type=primary  --socket-mem=1024 --file-prefix l3f -- 
-p 0x1 --config="(0,0,1),(0,1,2)"
Here is the log of app
"
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: VFIO support initialized
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
L3FWD: LPM or EM none selected, default LPM on
Initializing port 0 ... Creating queues: nb_rxq=2 nb_txq=4...  
Address:0C:C4:7A:73:EF:14, Destination:02:00:00:00:00:00, Allocated mbuf pool 
on socket 0
LPM: Adding route 0x01010100 / 24 (0)
LPM: Adding route IPV6 / 48 (0)
txq=1,0,0 txq=2,1,0 txq=9,2,0 txq=10,3,0

Skipping disabled port 1

Initializing rx queues on lcore 1 ... rxq=0,0,0
Initializing rx queues on lcore 2 ... rxq=0,1,0
Initializing rx queues on lcore 9 ...
Initializing rx queues on lcore 10 ...

"
It seems everything is good in this. So I tried to run pdump like

 ./dpdk_pdump -- --pdump 
'port=0,queue=*,rx-dev=/tmp/rx-file.pcap,tx-dev=/tmp/tx-file.pcap,ring-size=1024,mbuf-size=20,total-num-mbufs=1025'
Here is log for pdump

"
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL:   cannot connect to primary process!
EAL: VFIO support could not be initialized
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL:This may cause issues with mapping memory into secondary processes
EAL: Could not open /dev/hugepages/rtemap_510
PANIC in rte_eal_init():
Cannot init memory
6: [./dpdk_pdump(_start+0x29) [0x4289b9]]
5: [/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0) [0x7fa22219aa40]]
4: [./dpdk_pdump(main+0x155) [0x42c417]]
3: [./dpdk_pdump(rte_eal_init+0xf14) [0x4603b4]]
2: [./dpdk_pdump(__rte_panic+0xc9) [0x424b59]]
1: [./dpdk_pdump(rte_dump_stack+0x2b) [0x4677fb]]
Aborted (core dumped)

"

It seems from log that their is some issue in memory between primary and 
secondary, but when i tried to run one l2fwd as primary and one l3fwd as 
secondary it works fine.

On Fri, Jul 22, 2016 at 7:21 AM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi,

I see some cleanup related bug in the dpdk_pdump tool, so until I publish fix 
for that,
You need to restart  both primary and secondary process( work around) after you 
see any RING/VDEV failure issues.

Thanks,
Reshma


From: Pattan, Reshma
Sent: Friday, July 22, 2016 10:31 AM
To: 'Nishant Verma' mailto:vnish11 at gmail.com>>
Cc: users at dpdk.org<mailto:users at dpdk.org>
Subject: RE: pdump help

Hi,

As I see ?RING: Cannot reserve memory?. Please allocate enough huge page memory 

[dpdk-users] pdump help

2016-07-22 Thread Pattan, Reshma
Hi,

I see some cleanup related bug in the dpdk_pdump tool, so until I publish fix 
for that,
You need to restart  both primary and secondary process( work around) after you 
see any RING/VDEV failure issues.

Thanks,
Reshma


From: Pattan, Reshma
Sent: Friday, July 22, 2016 10:31 AM
To: 'Nishant Verma' 
Cc: users at dpdk.org
Subject: RE: pdump help

Hi,

As I see ?RING: Cannot reserve memory?. Please allocate enough huge page memory 
and see what happens.

Also once you encounter such error please restart  both primary and secondary 
process.

Please paste me the full  error log, if you still face the issue.

Thanks,
Reshma


From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Thursday, July 21, 2016 9:10 PM
To: Pattan, Reshma mailto:reshma.pattan at 
intel.com>>
Cc: users at dpdk.org<mailto:users at dpdk.org>
Subject: Re: pdump help

Hi Reshma,

Tried things pointed by you(libpcap Installed & config parameter is set).
But still things are not working.

"
root at ubuntu:/home/oneweb/dpdk/app/pdump# ./dpdk_pdump --proc-type=secondary 
-- --pdump 
'device_id=03:00.0,queue=*,rx-dev=/tmp/rx-file.pcap,tx-dev=/tmp/tx-file.pcap'
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL:This may cause issues with mapping memory into secondary processes
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
PMD: eth_ixgbe_dev_init(): No TX queues configured yet. Using default TX 
function.
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
RING: Cannot reserve memory
EAL: Error - exiting with code: 1
  Cause: File exists:create_mp_ring_vdev:649
"


Rgds,
Nishant


On Thu, Jul 21, 2016 at 5:16 AM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi,

Pdump tool is designed based on PCAP PMD. So you need to install libpcap 
package and set CONFIG_RTE_LIBRTE_PMD_PCAP flag to ?y?
in config/common_base file and recompile the DPDK and run pdump tool. Please 
let me know if that fix the issue.

This dependency is mentioned in the  document 
?doc/guides/sample_app_ug/pdump.rst.?

Thanks,
Reshma

From: Nishant Verma [mailto:vnish11 at gmail.com<mailto:vnis...@gmail.com>]
Sent: Wednesday, July 20, 2016 8:08 PM
To: Pattan, Reshma mailto:reshma.pattan at 
intel.com>>
Subject: pdump help

Hi Reshma,

i am facing some issue in executing pdump. I have seen in logs that you 
recently updated the code. Please let me know if i am doing anything wrong.


app/pdump# ./dpdk_pdump -- --pdump 
'device_id=03:00.0,queue=*,rx-dev=/tmp/rx-1-file.pcap,tx-dev=tx-1-file.pcap'

This is the error i am getting.
Cause: File exists:create_mp_ring_vdev:649

?Thanks a lot.?

--
Rgds,
Nishant






--
Rgds,
Nishant





[dpdk-users] pdump help

2016-07-22 Thread Pattan, Reshma
Hi,

As I see ?RING: Cannot reserve memory?. Please allocate enough huge page memory 
and see what happens.

Also once you encounter such error please restart  both primary and secondary 
process.

Please paste me the full  error log, if you still face the issue.

Thanks,
Reshma


From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Thursday, July 21, 2016 9:10 PM
To: Pattan, Reshma 
Cc: users at dpdk.org
Subject: Re: pdump help

Hi Reshma,

Tried things pointed by you(libpcap Installed & config parameter is set).
But still things are not working.

"
root at ubuntu:/home/oneweb/dpdk/app/pdump# ./dpdk_pdump --proc-type=secondary 
-- --pdump 
'device_id=03:00.0,queue=*,rx-dev=/tmp/rx-file.pcap,tx-dev=/tmp/tx-file.pcap'
EAL: Detected 16 lcore(s)
EAL: Probing VFIO support...
EAL: WARNING: Address Space Layout Randomization (ASLR) is enabled in the 
kernel.
EAL:This may cause issues with mapping memory into secondary processes
PMD: bnxt_rte_pmd_init() called for (null)
EAL: PCI device :03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
EAL: PCI device :03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:15ad rte_ixgbe_pmd
PMD: eth_ixgbe_dev_init(): No TX queues configured yet. Using default TX 
function.
EAL: PCI device :05:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
EAL: PCI device :05:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1521 rte_igb_pmd
RING: Cannot reserve memory
EAL: Error - exiting with code: 1
  Cause: File exists:create_mp_ring_vdev:649
"


Rgds,
Nishant


On Thu, Jul 21, 2016 at 5:16 AM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi,

Pdump tool is designed based on PCAP PMD. So you need to install libpcap 
package and set CONFIG_RTE_LIBRTE_PMD_PCAP flag to ?y?
in config/common_base file and recompile the DPDK and run pdump tool. Please 
let me know if that fix the issue.

This dependency is mentioned in the  document 
?doc/guides/sample_app_ug/pdump.rst.?

Thanks,
Reshma

From: Nishant Verma [mailto:vnish11 at gmail.com<mailto:vnis...@gmail.com>]
Sent: Wednesday, July 20, 2016 8:08 PM
To: Pattan, Reshma mailto:reshma.pattan at 
intel.com>>
Subject: pdump help

Hi Reshma,

i am facing some issue in executing pdump. I have seen in logs that you 
recently updated the code. Please let me know if i am doing anything wrong.


app/pdump# ./dpdk_pdump -- --pdump 
'device_id=03:00.0,queue=*,rx-dev=/tmp/rx-1-file.pcap,tx-dev=tx-1-file.pcap'

This is the error i am getting.
Cause: File exists:create_mp_ring_vdev:649

?Thanks a lot.?

--
Rgds,
Nishant






--
Rgds,
Nishant





[dpdk-users] pdump help

2016-07-21 Thread Pattan, Reshma
Hi,

Pdump tool is designed based on PCAP PMD. So you need to install libpcap 
package and set CONFIG_RTE_LIBRTE_PMD_PCAP flag to ?y?
in config/common_base file and recompile the DPDK and run pdump tool. Please 
let me know if that fix the issue.

This dependency is mentioned in the  document 
?doc/guides/sample_app_ug/pdump.rst.?

Thanks,
Reshma

From: Nishant Verma [mailto:vnis...@gmail.com]
Sent: Wednesday, July 20, 2016 8:08 PM
To: Pattan, Reshma 
Subject: pdump help

Hi Reshma,

i am facing some issue in executing pdump. I have seen in logs that you 
recently updated the code. Please let me know if i am doing anything wrong.


app/pdump# ./dpdk_pdump -- --pdump 
'device_id=03:00.0,queue=*,rx-dev=/tmp/rx-1-file.pcap,tx-dev=tx-1-file.pcap'

This is the error i am getting.
Cause: File exists:create_mp_ring_vdev:649

?Thanks a lot.?

--
Rgds,
Nishant





[dpdk-users] [dpdk-dev] capture packets on VM

2016-07-20 Thread Pattan, Reshma
Hi Raja,

You can use l3fwd  to forward packets to specific ports based on destination ip.
L3fwd uses LPM lookup to do destination based forwarding. As described in below 
 paragraph from the given link,
you need to add routing entry for the destinations ips of your interest and 
compile the code.

Place where routing entry should go is in below strut from file 
dpdk/examples/l3fwd/ l3fwd_lpm.c
static struct ipv4_l3fwd_lpm_route ipv4_l3fwd_lpm_route_array[] = {
{IPv4(1, 1, 1, 0), 24, 0},
{IPv4(2, 1, 1, 0), 24, 1},
{IPv4(3, 1, 1, 0), 24, 2},
{IPv4(4, 1, 1, 0), 24, 3},
{IPv4(5, 1, 1, 0), 24, 4},
{IPv4(6, 1, 1, 0), 24, 5},
{IPv4(7, 1, 1, 0), 24, 6},
{IPv4(8, 1, 1, 0), 24, 7},
};

http://dpdk.org/doc/guides-16.04/sample_app_ug/l3_forward.html
"The LPM lookup key is represented by the Destination IP Address field read 
from the input packet.
The ID of the output interface for the input packet is the next hop returned by 
the LPM lookup.
The set of LPM rules used by the application is statically configured and 
loaded into the LPM object at initialization time."

@Pablo: Do you know how MAC based forwarding can be done using L2?

Thanks,
Reshma


From: Raja Jayapal [mailto:raja.jaya...@tcs.com]
Sent: Wednesday, July 20, 2016 7:10 AM
To: Pattan, Reshma 
Cc: users at dpdk.org; De Lara Guarch, Pablo 
Subject: RE: [dpdk-dev] capture packets on VM

Hi Reshma/All,

Please find the "show config fwd" output below.

 testpmd> show config fwd
Warning! Cannot handle an odd number of ports with the current port topology. 
Configuration must be changed to have an even number of ports, or relaunch 
application with --port-topology=chained
io packet forwarding - ports=3 - cores=1 - streams=3 - NUMA support disabled, 
MP over anonymous pages disabled
Logical Core 1 (socket 0) forwards packets on 3 streams:
  RX P=0/Q=0 (socket 0) -> TX P=2/Q=0 (socket 0) peer=02:00:00:00:00:02
  RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00
  RX P=2/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00

As described above, i have modified the topology to have even number of ports.

testpmd> show config fwd
io packet forwarding - ports=4 - cores=1 - streams=4 - NUMA support disabled, 
MP over anonymous pages disabled
Logical Core 1 (socket 0) forwards packets on 4 streams:
  RX P=0/Q=0 (socket 0) -> TX P=1/Q=0 (socket 0) peer=02:00:00:00:00:01
  RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00
  RX P=2/Q=0 (socket 0) -> TX P=3/Q=0 (socket 0) peer=02:00:00:00:00:03
  RX P=3/Q=0 (socket 0) -> TX P=2/Q=0 (socket 0) peer=02:00:00:00:00:02

I could confirm that the packet is getting forwarded as per the config and 
setting the IP and MAC in packet generator does not take effect.
In testpmd app, whatever the MAC/IP is configured on traffic generator, the 
packets are forwaded in adjacent ports.

If i want to forward the packet based on IP&MAC, will it be achieved by running 
l2fwd or l3fwd ?

Kindly suggest.

Thanks,
Raja


-"Pattan, Reshma" mailto:reshma.pattan at 
intel.com>> wrote: -----
To: Raja Jayapal mailto:raja.jayapal at tcs.com>>
From: "Pattan, Reshma" mailto:reshma.pat...@intel.com>>
Date: 07/19/2016 07:12PM
Cc: "users at dpdk.org<mailto:users at dpdk.org>" mailto:users at dpdk.org>>, "De Lara Guarch, Pablo" 
mailto:pablo.de.lara.guarch at intel.com>>
Subject: RE: [dpdk-dev] capture packets on VM
Hi Raja,

Since this is a usability question this should be discussed under users at 
dpdk.org<mailto:users at dpdk.org> mailing list. Hence I removed dev at 
dpdk.org<mailto:dev at dpdk.org>.
Ya actually packets received from port 0 should be transmitted on to port1 and 
packets received from port1 should go to port2.

Can you paste o/p of  "show config fwd" and also interpret if  traffic on your 
board is flowing as per existing flow rules.

Ex:
testpmd> show  config fwd
io packet forwarding - ports=2 - cores=1 - streams=2 - NUMA support disabled, 
MP over anonymous pages disabled
Logical Core 5 (socket 0) forwards packets on 2 streams:
  RX P=0/Q=0 (socket 0) -> TX P=1/Q=0 (socket 0) peer=02:00:00:00:00:01  ==> 
this means, Streams received on port 0 will be sent on to port1 .
  RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00 ==> 
this means, Streams received on port1 will be sent onto port0.

Thanks,
Reshma

From: Raja Jayapal [mailto:raja.jaya...@tcs.com]
Sent: Tuesday, July 19, 2016 12:38 PM
To: Pattan, Reshma mailto:reshma.pattan at 
intel.com>>
Cc: dev at dpdk.org<mailto:dev at dpdk.org>
Subject: RE: [dpdk-dev] capture packets on VM

Hi Reshma,

Thanks for your information.
I have been trying to run the testpmd app and would like to get some idea on 
the packet flow in testpmd.

br0 -vnet0- (port0)VM NIC

br1--v

[dpdk-users] [dpdk-dev] capture packets on VM

2016-07-19 Thread Pattan, Reshma
Hi Raja,

Since this is a usability question this should be discussed under users at 
dpdk.org<mailto:users at dpdk.org> mailing list. Hence I removed dev at 
dpdk.org<mailto:dev at dpdk.org>.
Ya actually packets received from port 0 should be transmitted on to port1 and 
packets received from port1 should go to port2.

Can you paste o/p of  "show config fwd" and also interpret if  traffic on your 
board is flowing as per existing flow rules.

Ex:
testpmd> show  config fwd
io packet forwarding - ports=2 - cores=1 - streams=2 - NUMA support disabled, 
MP over anonymous pages disabled
Logical Core 5 (socket 0) forwards packets on 2 streams:
  RX P=0/Q=0 (socket 0) -> TX P=1/Q=0 (socket 0) peer=02:00:00:00:00:01  ==> 
this means, Streams received on port 0 will be sent on to port1 .
  RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00 ==> 
this means, Streams received on port1 will be sent onto port0.

Thanks,
Reshma

From: Raja Jayapal [mailto:raja.jaya...@tcs.com]
Sent: Tuesday, July 19, 2016 12:38 PM
To: Pattan, Reshma 
Cc: dev at dpdk.org
Subject: RE: [dpdk-dev] capture packets on VM

Hi Reshma,

Thanks for your information.
I have been trying to run the testpmd app and would like to get some idea on 
the packet flow in testpmd.

br0 -vnet0- (port0)VM NIC

br1--vnet1--(port1)VM NIC

br2--vnet2--(port2)VM NIC

br0 IP and MAC:
fe:54:00:0d:af:af - 192.168.100.10
br1 IP and MAC:
fe:54:00:4e:5b:df - 192.168.100.20
br2 IP and MAC:
fe:54:00:93:78:6d - 192.168.100.30

Ran testpmd application on VM and sending packets from Host using packeth.

Using PackETH generator, sent traffic from br0 destined to br1(modified the 
source / destination MAC and IP in packeth tool), but i could see that the 
packets are received on port0 and transmitted on port2.

Sending packets from br0 to br1:

./testpmd -c 3 -n 4 -- -i --total-num-mbufs=3000
testpmd> show port stats all
   NIC statistics for port 0  
  RX-packets: 4  RX-missed: 0  RX-bytes:  0
  RX-errors: 0
  RX-nombuf:  0
  TX-packets: 0  TX-errors: 0  TX-bytes:  0
  
   NIC statistics for port 1  
  RX-packets: 0  RX-missed: 0  RX-bytes:  0
  RX-errors: 0
  RX-nombuf:  0
  TX-packets: 0  TX-errors: 0  TX-bytes:  0
  
   NIC statistics for port 2  
  RX-packets: 0  RX-missed: 0  RX-bytes:  0
  RX-errors: 0
  RX-nombuf:  0
  TX-packets: 4  TX-errors: 0  TX-bytes:  0
  
testpmd>

Second time, sent traffic from br1 to br2, but the packets are received on 
port2 and transmitted on port0.

Sending packets from br1 to br2:

testpmd> show port stats all
   NIC statistics for port 0  
  RX-packets: 0  RX-missed: 0  RX-bytes:  0
  RX-errors: 0
  RX-nombuf:  0
  TX-packets: 6  TX-errors: 0  TX-bytes:  0
  
   NIC statistics for port 1  
  RX-packets: 6  RX-missed: 0  RX-bytes:  0
  RX-errors: 0
  RX-nombuf:  0
  TX-packets: 0  TX-errors: 0  TX-bytes:  0
  
   NIC statistics for port 2  
  RX-packets: 0  RX-missed: 0  RX-bytes:  0
  RX-errors: 0
  RX-nombuf:  0
  TX-packets: 0  TX-errors: 0  TX-bytes:  0
  
testpmd>

Could you please suggest whether this is expected behaviour?
Also suggest if any configuarion needs to be done to make the flow to work 
correctly.


Thanks,
Raja

-"Pattan, Reshma" mailto:reshma.pattan at 
intel.com>> wrote: -
To: Raja Jayapal mailto:raja.jayapal at tcs.com>>
From: "Pattan, Reshma" mailto:reshma.pat...@intel.com>>
Date: 07/15/2016 07:33PM
Cc: "dev at dpdk.org<mailto:dev at dpdk.org>" mailto:dev at 
dpdk.org>>
Subject: RE: [dpdk-dev] capture packets on VM

> -Original Message-
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Raja Jayapal
> Sent: Friday, July 15, 2016 6:55 AM
> To: dev at dpdk.org<mailto:dev at dpdk.org>
> Subject: [dpdk-dev] capture packets on VM
>
> Hi All,
>
> I have installed dpdk on VM and would like to know how to capture the packets
> on dpdk ports.
> I am sending traffic from host  and want to know 

[dpdk-users] Speed of NIC is showing only 100Mbps though it is 10G

2016-03-31 Thread Pattan, Reshma
Hi,

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of Mariappan
> Rajendran
> Sent: Thursday, March 24, 2016 11:41 AM
> To: users at dpdk.org
> Subject: [dpdk-users] Speed of NIC is showing only 100Mbps though it is 10G
> 
> Hi,
> 
> I am new to DPDK, as a first thing, i ran l2fwd app. I saw that it is 
> detecting the
> port0 NIC card, but the speed is showing as 100Mbps, though the NIC card is
> 10G speed capable.
> What could be the reason ?  Below is the log. I connected the NIC card to my
> LAN using cat6 cable, to reach this NIC card from my other machines in LAN.
> 
> FYI -
> 
> root at VFSR4:/home/hadmin/dpdk-2.2.0/examples/l2fwd# ./build/l2fwd -c f -n 4
> -- -q 8 -p 
> EAL: PCI device :01:00.0 on NUMA socket 0
> EAL:   probe driver: 8086:1528 rte_ixgbe_pmd
> EAL:   PCI memory mapped at 0x7f736760
> EAL:   PCI memory mapped at 0x7f7369167000
> PMD: eth_ixgbe_dev_init(): MAC: 4, PHY: 3

What is the NIC  type?  If it is 10GB, Ex: 82599ES 10-Gigabit SFI/SFP+ ? 
you should get above log as ex: "PMD: eth_ixgbe_dev_init(): MAC: 2, PHY: 18, 
SFP+: 5"
Will you  provide the  "./tools/dpdk_nic_bind.py  --status" output.

Thanks
Reshma



[dpdk-users] Attaching to an ethernet port from a secondary process

2016-02-19 Thread Pattan, Reshma
Hi,

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of Lazaros Koromilas
> Sent: Wednesday, February 17, 2016 11:40 AM
> To: users at dpdk.org
> Subject: Re: [dpdk-users] Attaching to an ethernet port from a secondary
> process
> 
> On Wed, Feb 17, 2016 at 1:17 PM, Lazaros Koromilas 
> wrote:
> > Hi all,
> >
> > I'm trying to take advantage of the multi-process support together
> > with the port hotplugging framework. The idea is that my primary
> > process will configure all ports I'm going to need and then secondary
> > processes will come up, selectively attach to ports and perform rx/tx.


[dpdk-users] Issue on Running KNI application

2015-12-09 Thread Pattan, Reshma
Hi Arun,

I see below EAL info from the given output, that means you have only 4 lcores 
on your board numbering 0, 1,2,3.
So you need to change the core mask and core numbering that you have passed  to 
--config.

> EAL: Detected 4 lcore(s)
> EAL: lcore 4 unavailable

Ex: if you want to use all 4 cores u need to try below command
 ./kni -c 0xf -n 4 -- -P -p 0x3 --config="(0,1,0),(1,2,3)"

-c 0xf  ==> enables all 4 cores 0,1,2,3
--config="(0,1,0),(1,2,3)"  ==>(0,1,0) core 1 is RX core and core 0 is TX 
core
==>(1,2,3) core 2 is RX core and core 3 is TX 
core

You can change RX and TX core numbers to your choice,  I just gave an example. 
But whatever cores you wants to use make sure those exists on board and should 
be enabled in core mask and the same should be used in config option.
You can check how many lcores are there on your board by using 
./too/cpu_layout.py

To check how to run KNI and understand command line options  take a look at KNI 
sample application section from Sample Application User guide.

Thanks,
Reshma

> -Original Message-
> From: P D, Arun (Nokia - IN/Bangalore) [mailto:arun.p_d at nokia.com]
> Sent: Wednesday, December 9, 2015 5:49 AM
> To: Pattan, Reshma
> Cc: users at dpdk.org
> Subject: RE: Issue on Running KNI application
> 
> Hi Reshma,
> 
> I am getting error, upon executing saying that it's an invalid core mask.
> 
> Also please let me know how you are calculating the hexadecimal bitmask for
> the cores.
> 
> ./kni -c 0x1E -n 4 -- -P -p 0x3 --config="(0,1,3),(1,2,4)"
> 
> EAL: Detected lcore 0 as core 0 on socket 0
> EAL: Detected lcore 1 as core 1 on socket 0
> EAL: Detected lcore 2 as core 2 on socket 0
> EAL: Detected lcore 3 as core 3 on socket 0
> EAL: Support maximum 128 logical core(s) by configuration.
> EAL: Detected 4 lcore(s)
> EAL: lcore 4 unavailable
> EAL: invalid coremask
> 
> Regards,
> Arun Raj
> 
> -Original Message-
> From: EXT Pattan, Reshma [mailto:reshma.pattan at intel.com]
> Sent: Wednesday, December 09, 2015 3:37 AM
> To: P D, Arun (Nokia - IN/Bangalore) ; users at 
> dpdk.org
> Subject: RE: Issue on Running KNI application
> 
> Hi Arun,
> 
> Core mask value i.e. -c value should be 0x1E in your command. Because you are
> using cores 1,2,3,4 so their respective bits must be set to 1 in -c value.
> 
> ./kni -c 0x1E -n 4 -- -P -p 0x3 --config="(0,1,3),(1,2,4)"
> 
> Thanks,
> Reshma
> 
> > -Original Message-
> > From: users [mailto:users-bounces at dpdk.org] On Behalf Of P D, Arun
> > (Nokia -
> > IN/Bangalore)
> > Sent: Tuesday, December 8, 2015 6:06 PM
> > To: users at dpdk.org
> > Subject: [dpdk-users] Issue on Running KNI application
> >
> > Hello,
> >
> > I am trying to run the KNI program in examples of dpdk.
> >
> > I am giving the following command and facing the error as  "Cause:
> > lcore id 1 for port 0 receiving not enabled".
> >
> > Please let me know if I am making any mistake at config parameters, or
> > I am missing something.
> >
> > ./kni -c 4 -n 4 -- -P -p 0x3 --config="(0,1,3),(1,2,4)"
> >
> > EAL: Detected lcore 0 as core 0 on socket 0
> > EAL: Detected lcore 1 as core 1 on socket 0
> > EAL: Detected lcore 2 as core 2 on socket 0
> > EAL: Detected lcore 3 as core 3 on socket 0
> > EAL: Support maximum 128 logical core(s) by configuration.
> > EAL: Detected 4 lcore(s)
> > EAL: Setting up physically contiguous memory...
> > EAL: Ask a virtual area of 0x20 bytes
> > EAL: Virtual area found at 0x7fd60360 (size = 0x20)
> > EAL: Ask a virtual area of 0x100 bytes
> > EAL: Virtual area found at 0x7fd60240 (size = 0x100)
> > EAL: Ask a virtual area of 0x3c0 bytes
> > EAL: Virtual area found at 0x7fd5fe60 (size = 0x3c0)
> > EAL: Ask a virtual area of 0x5040 bytes
> > EAL: Virtual area found at 0x7fd5ae00 (size = 0x5040)
> > EAL: Ask a virtual area of 0x29c0 bytes
> > EAL: Virtual area found at 0x7fd58420 (size = 0x29c0)
> > EAL: Ask a virtual area of 0x100 bytes
> > EAL: Virtual area found at 0x7fd58300 (size = 0x100)
> > EAL: Ask a virtual area of 0x20 bytes
> > EAL: Virtual area found at 0x7fd582c0 (size = 0x20)
> > EAL: Requesting 1024 pages of size 2MB from socket 0
> > EAL: TSC frequency is ~3192614 KHz
> > EAL: Master lcore 2 is ready (tid=3cb98e0;cpuset=[2])
> > EAL: PCI device :03:00.0 on NUMA socket -1
> > EAL:   probe driver: 8086:1533 rte_igb_pmd
> > EAL:   Not managed b

[dpdk-users] Issue on Running KNI application

2015-12-08 Thread Pattan, Reshma
Hi Arun,

Core mask value i.e. -c value should be 0x1E in your command. Because you are 
using cores 1,2,3,4 so their respective bits must be set to 1 in -c value.

./kni -c 0x1E -n 4 -- -P -p 0x3 --config="(0,1,3),(1,2,4)"

Thanks,
Reshma

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of P D, Arun (Nokia -
> IN/Bangalore)
> Sent: Tuesday, December 8, 2015 6:06 PM
> To: users at dpdk.org
> Subject: [dpdk-users] Issue on Running KNI application
> 
> Hello,
> 
> I am trying to run the KNI program in examples of dpdk.
> 
> I am giving the following command and facing the error as  "Cause: lcore id 1 
> for
> port 0 receiving not enabled".
> 
> Please let me know if I am making any mistake at config parameters, or I am
> missing something.
> 
> ./kni -c 4 -n 4 -- -P -p 0x3 --config="(0,1,3),(1,2,4)"
> 
> EAL: Detected lcore 0 as core 0 on socket 0
> EAL: Detected lcore 1 as core 1 on socket 0
> EAL: Detected lcore 2 as core 2 on socket 0
> EAL: Detected lcore 3 as core 3 on socket 0
> EAL: Support maximum 128 logical core(s) by configuration.
> EAL: Detected 4 lcore(s)
> EAL: Setting up physically contiguous memory...
> EAL: Ask a virtual area of 0x20 bytes
> EAL: Virtual area found at 0x7fd60360 (size = 0x20)
> EAL: Ask a virtual area of 0x100 bytes
> EAL: Virtual area found at 0x7fd60240 (size = 0x100)
> EAL: Ask a virtual area of 0x3c0 bytes
> EAL: Virtual area found at 0x7fd5fe60 (size = 0x3c0)
> EAL: Ask a virtual area of 0x5040 bytes
> EAL: Virtual area found at 0x7fd5ae00 (size = 0x5040)
> EAL: Ask a virtual area of 0x29c0 bytes
> EAL: Virtual area found at 0x7fd58420 (size = 0x29c0)
> EAL: Ask a virtual area of 0x100 bytes
> EAL: Virtual area found at 0x7fd58300 (size = 0x100)
> EAL: Ask a virtual area of 0x20 bytes
> EAL: Virtual area found at 0x7fd582c0 (size = 0x20)
> EAL: Requesting 1024 pages of size 2MB from socket 0
> EAL: TSC frequency is ~3192614 KHz
> EAL: Master lcore 2 is ready (tid=3cb98e0;cpuset=[2])
> EAL: PCI device :03:00.0 on NUMA socket -1
> EAL:   probe driver: 8086:1533 rte_igb_pmd
> EAL:   Not managed by a supported kernel driver, skipped
> EAL: PCI device :05:00.0 on NUMA socket -1
> EAL:   probe driver: 8086:100e rte_em_pmd
> EAL:   Not managed by a supported kernel driver, skipped
> EAL: PCI device :06:00.0 on NUMA socket -1
> EAL:   probe driver: 8086:10d3 rte_em_pmd
> EAL:   Not managed by a supported kernel driver, skipped
> APP: Port ID: 0
> APP: Rx lcore ID: 1, Tx lcore ID: 3
> APP: Port ID: 1
> APP: Rx lcore ID: 2, Tx lcore ID: 4
> EAL: Error - exiting with code: 1
>   Cause: lcore id 1 for port 0 receiving not enabled
> 
> Regards,
> Arun Raj



[dpdk-users] DPDK KNI Issue

2015-12-07 Thread Pattan, Reshma
Hi Ilir,

Can you reiterate the test as suggested below. Because during KNI testing I 
observed one weird behavior that, If we keep running tcpdump on KNI device and 
try to terminate KNI application with cntl+c/ or by other means it doesn?t get 
terminated. In such case  we need to kill tcpdump first then KNI application. 
After doing this, for next round dpdk bounded ports are not receiving any 
traffic. So I suggest you to do below steps.

a)terminate tcpdump and KNI application
b)unbind DPDK ports from igb_uio.
c)bind back DPDK ports to igb_uio.
d)run test_pmd application and make sure traffic is been received on the ports. 
 If traffic is received ,
e)then run KNI application
d)run tcpdump on KNI device

Let me know how things goes.

Thanks,
Reshma
From: Ilir Iljazi [mailto:ilj...@gmail.com]
Sent: Friday, December 4, 2015 5:54 PM
To: Pattan, Reshma
Subject: Re: [dpdk-users] DPDK KNI Issue

Hi thanks again. I'm using the example application to create the interface:

./examples/kni/build/app/kni -n 4 -c 0xff -- -p 0x1 -P --config="(0,5,7)" &

The interface is created and I'm able to configure it just like any other linux 
interface via IP/subnet default route etc. I haven't written my application yet 
because I can't get basic functionality working such as connect and data xfer. 
Hence, the debug isn't expected to help since the routines posted are not 
called. Regarding the proc file system monitoring, same answer there is no 
application yet.

Thanks,
Ilir

On Fri, Dec 4, 2015 at 11:13 AM, Pattan, Reshma mailto:reshma.pattan at intel.com>> wrote:
Hi,

Are you using dpdk kni sample application? (Or) you have your own module with 
KNI implementation? If so please share the code will look into.

Can you also check by adding enough logging  to below functions .
a)kni_net_rx_normal and other kni_next_rx_* functions if they are invoked  by 
DPDK to push packets to TCPIP stack.
b)kni_net_tx being invoked by TCP/IP stack to push packets to DPDK.

Also, you can use app/proc_info app from DPDK  2.1 release to check packet 
statistics of DPDK ports, to see what is happening.

Thanks,
Reshma

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org<mailto:users-bounces at 
> dpdk.org>] On Behalf Of Pattan, Reshma
> Sent: Friday, December 4, 2015 12:28 PM
> To: Ilir Iljazi; users at dpdk.org<mailto:users at dpdk.org>
> Subject: Re: [dpdk-users] DPDK KNI Issue
>
> Hi,
>
> I had tried KNI ping testing on fedora ,  DPDK2.2 and using one loopback
> connection, it works fine and I tried without steps 9 and 10.
> I am not sure why steps 9 & 10 are needed in your case, but you can try 
> without
> those 2 steps and see the results.
> Also, after you start the ping, make sure there is no core dump in dmesg for 
> KNI
> module.
> If ur running tcpdump with icmp filter try running without filter and first 
> see if
> ARP packets are reaching to KNI or not.
> Also can you check if packet drop stats of kni iface increasing?
>
> Thanks,
> Reshma
>
> > -Original Message-
> > From: users [mailto:users-bounces at dpdk.org<mailto:users-bounces at 
> > dpdk.org>] On Behalf Of Ilir Iljazi
> > Sent: Thursday, December 3, 2015 9:55 PM
> > To: users at dpdk.org<mailto:users at dpdk.org>
> > Subject: [dpdk-users] DPDK KNI Issue
> >
> > Hi,
> > I have been having an issue with dpdk kni whereby I cant send and
> > receive packets from the kni interface. I spent about a week trying to
> > figure it out the issue myself to no avail. Although I did find
> > articles with a similar signature to mine none of the proposed solutions 
> > helped
> solve the problem.
> >
> > Environment:
> > Ubuntu Server 14.04
> > DPDK Package 2.1.0 (Latest)
> > Network Card: (10Gbe ixgbe driver)
> >
> > 06:00.0 Ethernet controller: Intel Corporation 82599ES 10-Gigabit
> > SFI/SFP+ Network Connection
> > 06:00.1 Ethernet controller: Intel Corporation 82599ES 10-Gigabit
> > SFI/SFP+ Network Connection
> >
> > 06.00.0 (port 0 connected to switch)
> > 06:00.1 (port 1 not connected to switch)
> >
> > Configuration:
> > 1.) DPDK built without issue
> > 2.) Modules Loaded:
> >
> > insmod $RTE_TARGET/kmod/igb_uio.ko
> > insmod $RTE_TARGET/kmod/rte_kni.ko kthread_mode=multiple
> >
> >
> > 3.) Reserved Huge Pages:
> >
> > echo 4096 >
> > /sys/devices/system/node/node0/hugepages/hugepages-
> 2048kB/nr_hugepages
> > echo 4096 >
> > /sys/devices/system/node/node1/hugepages/hugepages-
> 2048kB/nr_hugepages
> >
> >
> > 4.) Mounted huge page partition
> >
> > echo ">>> Mounting huge page partition"

[dpdk-users] DPDK KNI Issue

2015-12-04 Thread Pattan, Reshma
Hi,

I had tried KNI ping testing on fedora ,  DPDK2.2 and using one loopback 
connection, it works fine and I tried without steps 9 and 10.
I am not sure why steps 9 & 10 are needed in your case, but you can try without 
those 2 steps and see the results. 
Also, after you start the ping, make sure there is no core dump in dmesg for 
KNI module.
If ur running tcpdump with icmp filter try running without filter and first see 
if ARP packets are reaching to KNI or not.
Also can you check if packet drop stats of kni iface increasing?

Thanks,
Reshma

> -Original Message-
> From: users [mailto:users-bounces at dpdk.org] On Behalf Of Ilir Iljazi
> Sent: Thursday, December 3, 2015 9:55 PM
> To: users at dpdk.org
> Subject: [dpdk-users] DPDK KNI Issue
> 
> Hi,
> I have been having an issue with dpdk kni whereby I cant send and receive
> packets from the kni interface. I spent about a week trying to figure it out 
> the
> issue myself to no avail. Although I did find articles with a similar 
> signature to
> mine none of the proposed solutions helped solve the problem.
> 
> Environment:
> Ubuntu Server 14.04
> DPDK Package 2.1.0 (Latest)
> Network Card: (10Gbe ixgbe driver)
> 
> 06:00.0 Ethernet controller: Intel Corporation 82599ES 10-Gigabit SFI/SFP+
> Network Connection
> 06:00.1 Ethernet controller: Intel Corporation 82599ES 10-Gigabit SFI/SFP+
> Network Connection
> 
> 06.00.0 (port 0 connected to switch)
> 06:00.1 (port 1 not connected to switch)
> 
> Configuration:
> 1.) DPDK built without issue
> 2.) Modules Loaded:
> 
> insmod $RTE_TARGET/kmod/igb_uio.ko
> insmod $RTE_TARGET/kmod/rte_kni.ko kthread_mode=multiple
> 
> 
> 3.) Reserved Huge Pages:
> 
> echo 4096 >
> /sys/devices/system/node/node0/hugepages/hugepages-2048kB/nr_hugepages
> echo 4096 >
> /sys/devices/system/node/node1/hugepages/hugepages-2048kB/nr_hugepages
> 
> 
> 4.) Mounted huge page partition
> 
> echo ">>> Mounting huge page partition"
> mkdir -p /mnt/huge
> mount -t hugetlbfs nodev /mnt/huge
> 
> 
> 5.) Interfaces 06:00.0/1 bound to igb uio module (option 19 on setup)
> 
> Network devices using DPDK-compatible driver
> 
> :06:00.0 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
> unused=
> :06:00.1 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
> unused=
> 
> 
> 6.) Started kni test application:
> 
> Command: ./examples/kni/build/app/kni -n 4 -c 0xff -- -p 0x1 -P --
> config="(0,5,7)" &
> 
> Output:
> 
> EAL: PCI device :06:00.0 on NUMA socket -1
> EAL:   probe driver: 8086:10fb rte_ixgbe_pmd
> EAL:   PCI memory mapped at 0x7fcda5c0
> EAL:   PCI memory mapped at 0x7fcda5c8
> PMD: eth_ixgbe_dev_init(): MAC: 2, PHY: 18, SFP+: 5
> PMD: eth_ixgbe_dev_init(): port 0 vendorID=0x8086 deviceID=0x10fb
> EAL: PCI device :06:00.1 on NUMA socket -1
> EAL:   probe driver: 8086:10fb rte_ixgbe_pmd
> EAL:   PCI memory mapped at 0x7fcda5c84000
> EAL:   PCI memory mapped at 0x7fcda5d04000
> PMD: eth_ixgbe_dev_init(): MAC: 2, PHY: 18, SFP+: 6
> PMD: eth_ixgbe_dev_init(): port 1 vendorID=0x8086 deviceID=0x10fb
> APP: Port ID: 0
> APP: Rx lcore ID: 5, Tx lcore ID: 7
> APP: Initialising port 0 ...
> PMD: ixgbe_dev_rx_queue_setup(): sw_ring=0x7fcd5c1adcc0
> sw_sc_ring=0x7fcd5c1ad780 hw_ring=0x7fcd5c1ae200 dma_addr=0xe5b1ae200
> PMD: ixgbe_dev_tx_queue_setup(): sw_ring=0x7fcd5c19b5c0
> hw_ring=0x7fcd5c19d600 dma_addr=0xe5b19d600
> PMD: ixgbe_set_tx_function(): Using simple tx code path
> PMD: ixgbe_set_tx_function(): Vector tx enabled.
> PMD: ixgbe_set_rx_function(): Vector rx enabled, please make sure RX burst 
> size
> no less than 32.
> KNI: pci: 06:00:00  8086:10fb
> 
> 
> Checking link status
> done
> Port 0 Link Up - speed 1 Mbps - full-duplex
> APP: Lcore 1 has nothing to do
> APP: Lcore 2 has nothing to do
> APP: Lcore 3 has nothing to do
> APP: Lcore 4 has nothing to do
> APP: Lcore 5 is reading from port 0
> APP: Lcore 6 has nothing to do
> APP: Lcore 7 is writing to port 0
> APP: Lcore 0 has nothing to do
> 
> 
> 7.) KNI interface configured and brought up:
> 
> root at l3sys2-acc2-3329:~/dpdk-2.1.0# ifconfig vEth0 192.168.13.95 netmask
> 255.255.248.0 up
> APP: Configure network interface of 0 up
> PMD: ixgbe_set_rx_function(): Vector rx enabled, please make sure RX burst 
> size
> no less than 32.
> 
> root at l3sys2-acc2-3329:~/dpdk-2.1.0# ifconfig vEth0
> 
> vEth0 Link encap:Ethernet  HWaddr 90:e2:ba:55:fd:c4
>   inet addr:192.168.13.95  Bcast:192.168.15.255  Mask:255.255.248.0
>   inet6 addr: fe80::92e2:baff:fe55:fdc4/64 Scope:Link
>   UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>   RX packets:0 errors:0 dropped:0 overruns:0 frame:0
>   TX packets:0 errors:0 dropped:8 overruns:0 carrier:0
>   collisions:0 txqueuelen:1000
>   RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
> 
> Note also that dmesg is clean not pointing to any issues:
> [ 1770.113952] KNI: /dev/kni opened
> [ 1770.5619