All of lore.kernel.org
 help / color / mirror / Atom feed
* Help: How to read packet statistics from device registers via dpdk PMD?
@ 2016-07-05  7:35 Bill Bonaparte
  2016-07-05 12:03 ` Jay Rolette
  0 siblings, 1 reply; 5+ messages in thread
From: Bill Bonaparte @ 2016-07-05  7:35 UTC (permalink / raw)
  To: dev

Hi:
I am a new fish, I have tried my best to find answer about my question on
web, but I failed. so
I come here to ask for your help. the below is my question:

I found that dpdk provides a api rte_eth_stats_get to read packet
statistics about the interface, includes total input/output
unicast/multicast/brodcast packets/bytes. but the api does not work on
VMxnet interface (which is a virtual interface in VMware machine).

I am not sure if this api works for the real interface.
who has more information about this, and why it does not work on virtual
machine ?

Appreciate any comments and reply.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Help: How to read packet statistics from device registers via dpdk PMD?
  2016-07-05  7:35 Help: How to read packet statistics from device registers via dpdk PMD? Bill Bonaparte
@ 2016-07-05 12:03 ` Jay Rolette
  2016-07-07  5:52   ` Bill Bonaparte
  0 siblings, 1 reply; 5+ messages in thread
From: Jay Rolette @ 2016-07-05 12:03 UTC (permalink / raw)
  To: Bill Bonaparte; +Cc: DPDK

On Tue, Jul 5, 2016 at 2:35 AM, Bill Bonaparte <programme110@gmail.com>
wrote:

> Hi:
> I am a new fish, I have tried my best to find answer about my question on
> web, but I failed. so
> I come here to ask for your help. the below is my question:
>
> I found that dpdk provides a api rte_eth_stats_get to read packet
> statistics about the interface, includes total input/output
> unicast/multicast/brodcast packets/bytes. but the api does not work on
> VMxnet interface (which is a virtual interface in VMware machine).
>

Probably something in your app or environment rather than in the API
itself. We run rte_eth_stats_get() against interfaces in VMware Fusion,
VirtualBox and real hardware and they all work generally.

Need some info before anyone can help you much:

* What version of DPDK are you running?
* What OS are you running on?
* Output from "dpdk_nic_bind.py --status"?

Jay

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Help: How to read packet statistics from device registers via dpdk PMD?
  2016-07-05 12:03 ` Jay Rolette
@ 2016-07-07  5:52   ` Bill Bonaparte
  2016-07-07 12:19     ` Jay Rolette
  0 siblings, 1 reply; 5+ messages in thread
From: Bill Bonaparte @ 2016-07-07  5:52 UTC (permalink / raw)
  To: Jay Rolette; +Cc: DPDK

I am so happy to get your reply.
My dpdk version is 2.1,and the OS is centOS 7。
the following is the output from "dpdk_nic_bind.py --status":

[root@APV35 ~]# dpdk_nic_bind.py --status

Network devices using DPDK-compatible driver
============================================
0000:04:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
0000:0b:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
0000:13:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
0000:1b:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=

Network devices using kernel driver
===================================
0000:03:00.0 'VMXNET3 Ethernet Controller' if=ens160 drv=vmxnet3
unused=igb_uio *Active*

Other network devices
=====================
<none>

I tried it on the physical mathine, it still does not work. the OS is
centOS 7, too.
[root@AN ~]# dpdk_nic_bind.py --status

Network devices using DPDK-compatible driver
============================================
0000:01:00.0 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
unused=
0000:01:00.1 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
unused=
0000:03:00.0 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
0000:03:00.1 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
0000:03:00.2 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
0000:03:00.3 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
0000:07:00.0 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:07:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:07:00.2 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:07:00.3 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:09:00.0 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:09:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:09:00.2 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:09:00.3 'I350 Gigabit Network Connection' drv=igb_uio unused=
0000:0c:00.0 'Device 0011' drv=igb_uio unused=
0000:0f:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=

Network devices using kernel driver
===================================
0000:0f:00.0 'I350 Gigabit Network Connection' if=enp15s0f0 drv=igb
unused=igb_uio *Active*

Other network devices
=====================
<none>


On Tue, Jul 5, 2016 at 8:03 PM, Jay Rolette <rolette@infinite.io> wrote:

>
> On Tue, Jul 5, 2016 at 2:35 AM, Bill Bonaparte <programme110@gmail.com>
> wrote:
>
>> Hi:
>> I am a new fish, I have tried my best to find answer about my question on
>> web, but I failed. so
>> I come here to ask for your help. the below is my question:
>>
>> I found that dpdk provides a api rte_eth_stats_get to read packet
>> statistics about the interface, includes total input/output
>> unicast/multicast/brodcast packets/bytes. but the api does not work on
>> VMxnet interface (which is a virtual interface in VMware machine).
>>
>
> Probably something in your app or environment rather than in the API
> itself. We run rte_eth_stats_get() against interfaces in VMware Fusion,
> VirtualBox and real hardware and they all work generally.
>
> Need some info before anyone can help you much:
>
> * What version of DPDK are you running?
> * What OS are you running on?
> * Output from "dpdk_nic_bind.py --status"?
>
> Jay
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Help: How to read packet statistics from device registers via dpdk PMD?
  2016-07-07  5:52   ` Bill Bonaparte
@ 2016-07-07 12:19     ` Jay Rolette
  2016-07-12 12:00       ` Bill Bonaparte
  0 siblings, 1 reply; 5+ messages in thread
From: Jay Rolette @ 2016-07-07 12:19 UTC (permalink / raw)
  To: Bill Bonaparte; +Cc: DPDK

On Thu, Jul 7, 2016 at 12:52 AM, Bill Bonaparte <programme110@gmail.com>
wrote:

> I am so happy to get your reply.
> My dpdk version is 2.1,and the OS is centOS 7。
> the following is the output from "dpdk_nic_bind.py --status":
>
> [root@APV35 ~]# dpdk_nic_bind.py --status
>
> Network devices using DPDK-compatible driver
> ============================================
> 0000:04:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
> 0000:0b:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
> 0000:13:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
> 0000:1b:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
>
> Network devices using kernel driver
> ===================================
> 0000:03:00.0 'VMXNET3 Ethernet Controller' if=ens160 drv=vmxnet3
> unused=igb_uio *Active*
>
> Other network devices
> =====================
> <none>
>

That's a different virtual NIC than what I'm running in my VMs, but given
your app isn't working directly on the hardware, I doubt that's the issue.
In case it helps along the way, here's what I see in my VM:

$ dpdk_nic_bind.py --status

Network devices using DPDK-compatible driver
============================================
0000:02:02.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
unused=
0000:02:03.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
unused=
0000:02:04.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
unused=
0000:02:05.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
unused=

Network devices using kernel driver
===================================
0000:02:01.0 '82545EM Gigabit Ethernet Controller (Copper)' if=eth0
drv=e1000 unused=igb_uio *Active*

Other network devices
=====================
<none>


> I tried it on the physical mathine, it still does not work. the OS is
> centOS 7, too.
> [root@AN ~]# dpdk_nic_bind.py --status
>
> Network devices using DPDK-compatible driver
> ============================================
> 0000:01:00.0 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
> unused=
> 0000:01:00.1 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
> unused=
> 0000:03:00.0 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
> 0000:03:00.1 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
> 0000:03:00.2 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
> 0000:03:00.3 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
> 0000:07:00.0 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:07:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:07:00.2 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:07:00.3 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:09:00.0 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:09:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:09:00.2 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:09:00.3 'I350 Gigabit Network Connection' drv=igb_uio unused=
> 0000:0c:00.0 'Device 0011' drv=igb_uio unused=
> 0000:0f:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
>
> Network devices using kernel driver
> ===================================
> 0000:0f:00.0 'I350 Gigabit Network Connection' if=enp15s0f0 drv=igb
> unused=igb_uio *Active*
>
> Other network devices
> =====================
> <none>
>

With it not working on hardware and you having devices successfully bound
to DPDK, maybe it's a problem in your app. Have you tried running any of
the sample apps that use rte_eth_stats_get() and see if it works there?

Jay


> On Tue, Jul 5, 2016 at 8:03 PM, Jay Rolette <rolette@infinite.io> wrote:
>
>>
>> On Tue, Jul 5, 2016 at 2:35 AM, Bill Bonaparte <programme110@gmail.com>
>> wrote:
>>
>>> Hi:
>>> I am a new fish, I have tried my best to find answer about my question on
>>> web, but I failed. so
>>> I come here to ask for your help. the below is my question:
>>>
>>> I found that dpdk provides a api rte_eth_stats_get to read packet
>>> statistics about the interface, includes total input/output
>>> unicast/multicast/brodcast packets/bytes. but the api does not work on
>>> VMxnet interface (which is a virtual interface in VMware machine).
>>>
>>
>> Probably something in your app or environment rather than in the API
>> itself. We run rte_eth_stats_get() against interfaces in VMware Fusion,
>> VirtualBox and real hardware and they all work generally.
>>
>> Need some info before anyone can help you much:
>>
>> * What version of DPDK are you running?
>> * What OS are you running on?
>> * Output from "dpdk_nic_bind.py --status"?
>>
>> Jay
>>
>
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Help: How to read packet statistics from device registers via dpdk PMD?
  2016-07-07 12:19     ` Jay Rolette
@ 2016-07-12 12:00       ` Bill Bonaparte
  0 siblings, 0 replies; 5+ messages in thread
From: Bill Bonaparte @ 2016-07-12 12:00 UTC (permalink / raw)
  To: Jay Rolette; +Cc: DPDK

Hi, Jay:
      My apologies for taking me to get back to you.
      I tried the sample apps on my environment follow your advice, and I
found it works well.
      so I started to compare  the code related to the api between my app
and the sample app, I didn't find any significative difference. I am very
confused.
      .....
      finnaly, with the help of my colleague, I tracked down the problem.
It's a confused character of my platform that make the packets miss  the
interface which I monitored.
      so I can access the IP of the interface, but the flow don't pass
through the interface.
      after ajusting the topology, the api works well.

     anyhow, thanks to your advice, I tracked down the problem.
     so again, I appreciate your time in talking with me about this api.

On Thu, Jul 7, 2016 at 8:19 PM, Jay Rolette <rolette@infinite.io> wrote:

>
> On Thu, Jul 7, 2016 at 12:52 AM, Bill Bonaparte <programme110@gmail.com>
> wrote:
>
>> I am so happy to get your reply.
>> My dpdk version is 2.1,and the OS is centOS 7。
>> the following is the output from "dpdk_nic_bind.py --status":
>>
>> [root@APV35 ~]# dpdk_nic_bind.py --status
>>
>> Network devices using DPDK-compatible driver
>> ============================================
>> 0000:04:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
>> 0000:0b:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
>> 0000:13:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
>> 0000:1b:00.0 'VMXNET3 Ethernet Controller' drv=igb_uio unused=
>>
>> Network devices using kernel driver
>> ===================================
>> 0000:03:00.0 'VMXNET3 Ethernet Controller' if=ens160 drv=vmxnet3
>> unused=igb_uio *Active*
>>
>> Other network devices
>> =====================
>> <none>
>>
>
> That's a different virtual NIC than what I'm running in my VMs, but given
> your app isn't working directly on the hardware, I doubt that's the issue.
> In case it helps along the way, here's what I see in my VM:
>
> $ dpdk_nic_bind.py --status
>
> Network devices using DPDK-compatible driver
> ============================================
> 0000:02:02.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
> unused=
> 0000:02:03.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
> unused=
> 0000:02:04.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
> unused=
> 0000:02:05.0 '82545EM Gigabit Ethernet Controller (Copper)' drv=igb_uio
> unused=
>
> Network devices using kernel driver
> ===================================
> 0000:02:01.0 '82545EM Gigabit Ethernet Controller (Copper)' if=eth0
> drv=e1000 unused=igb_uio *Active*
>
> Other network devices
> =====================
> <none>
>
>
>> I tried it on the physical mathine, it still does not work. the OS is
>> centOS 7, too.
>> [root@AN ~]# dpdk_nic_bind.py --status
>>
>> Network devices using DPDK-compatible driver
>> ============================================
>> 0000:01:00.0 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
>> unused=
>> 0000:01:00.1 '82599ES 10-Gigabit SFI/SFP+ Network Connection' drv=igb_uio
>> unused=
>> 0000:03:00.0 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
>> 0000:03:00.1 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
>> 0000:03:00.2 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
>> 0000:03:00.3 'I350 Gigabit Backplane Connection' drv=igb_uio unused=
>> 0000:07:00.0 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:07:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:07:00.2 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:07:00.3 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:09:00.0 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:09:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:09:00.2 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:09:00.3 'I350 Gigabit Network Connection' drv=igb_uio unused=
>> 0000:0c:00.0 'Device 0011' drv=igb_uio unused=
>> 0000:0f:00.1 'I350 Gigabit Network Connection' drv=igb_uio unused=
>>
>> Network devices using kernel driver
>> ===================================
>> 0000:0f:00.0 'I350 Gigabit Network Connection' if=enp15s0f0 drv=igb
>> unused=igb_uio *Active*
>>
>> Other network devices
>> =====================
>> <none>
>>
>
> With it not working on hardware and you having devices successfully bound
> to DPDK, maybe it's a problem in your app. Have you tried running any of
> the sample apps that use rte_eth_stats_get() and see if it works there?
>
> Jay
>
>
>> On Tue, Jul 5, 2016 at 8:03 PM, Jay Rolette <rolette@infinite.io> wrote:
>>
>>>
>>> On Tue, Jul 5, 2016 at 2:35 AM, Bill Bonaparte <programme110@gmail.com>
>>> wrote:
>>>
>>>> Hi:
>>>> I am a new fish, I have tried my best to find answer about my question
>>>> on
>>>> web, but I failed. so
>>>> I come here to ask for your help. the below is my question:
>>>>
>>>> I found that dpdk provides a api rte_eth_stats_get to read packet
>>>> statistics about the interface, includes total input/output
>>>> unicast/multicast/brodcast packets/bytes. but the api does not work on
>>>> VMxnet interface (which is a virtual interface in VMware machine).
>>>>
>>>
>>> Probably something in your app or environment rather than in the API
>>> itself. We run rte_eth_stats_get() against interfaces in VMware Fusion,
>>> VirtualBox and real hardware and they all work generally.
>>>
>>> Need some info before anyone can help you much:
>>>
>>> * What version of DPDK are you running?
>>> * What OS are you running on?
>>> * Output from "dpdk_nic_bind.py --status"?
>>>
>>> Jay
>>>
>>
>>
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-07-12 12:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-05  7:35 Help: How to read packet statistics from device registers via dpdk PMD? Bill Bonaparte
2016-07-05 12:03 ` Jay Rolette
2016-07-07  5:52   ` Bill Bonaparte
2016-07-07 12:19     ` Jay Rolette
2016-07-12 12:00       ` Bill Bonaparte

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.