From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-io0-f179.google.com (mail-io0-f179.google.com [209.85.223.179]) by dpdk.org (Postfix) with ESMTP id D62092C5D for ; Wed, 11 May 2016 15:45:10 +0200 (CEST) Received: by mail-io0-f179.google.com with SMTP id d62so54496012iof.2 for ; Wed, 11 May 2016 06:45:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=DkFFsM9nr7CrTLlN/0JjQ9NbM3m3ruK9WS7xPmY0/3I=; b=ovkkTKJEZRrzZqbgk49wauPNWaggivr1W41iM4meXMAzJrfXKP65Z5FENSQCPo9gVo 4WFZpHKkl0NXXLKQNtSMPHIBgOQ9GB2Qh0TRiwJPwRj2vszU68tNt3sv5goy58q7R//A SclICnGbykWfmTS43ky4MZhuZoBMpDnY4vdlf3sB/nz55mGfRTqGItuwxevBmeVZsmBD MTtoI/gGbo8gVx7ZHcAUnneKADnqJ600pRq7hJiJAOCXj+BApWC54k/JwqJBlc2La+qR nxgY/vojTCa5YI42YFmCSdaQzLdNjMcORcMxEpsy/dvxDUsBpmPpAQajNbl2XBHNM6c3 s3Xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=DkFFsM9nr7CrTLlN/0JjQ9NbM3m3ruK9WS7xPmY0/3I=; b=jQUMxfyGPt59ySUPOIKlFF2YJgGgpX9yfDFs5kYr6sM2f8ilMEgitz4iLuD1bTNUbC MDgslhNIfQOlaKfdiL7kRd6aEMbmg27i2SpwTMfGIPouwXrdEqMHa9UaO/NnDdfb0sSM iwt+cXkues1amfL8WXHUZIOEQ3wQADUp2G/U/LJLnP7rniBJKQvo1OFe2Wel7Iz8XFrJ Eo8LPiBU5ogtFTsUNv33SIsZuY9JauGPpYVdZYhZMU76HmYzzxa5/YeU8QUMmOnqxOec mXYKbPvvGqSCKCrqAFzwRcIp3hRb3FsNqsuZBfuF1zWDi3dC+87MYVN9uIUFMcHYgHBX v3cg== X-Gm-Message-State: AOPr4FWvzv3FoFbdvK2np2Ep2JfcoEBDLx5RoaIW87qwKHUHsIHt6L6e4RbRIrHXd2Qg4iHFAAHlSVQsiwr0Og== X-Received: by 10.36.76.88 with SMTP id a85mr4732650itb.11.1462974310242; Wed, 11 May 2016 06:45:10 -0700 (PDT) MIME-Version: 1.0 Received: by 10.79.4.130 with HTTP; Wed, 11 May 2016 06:44:50 -0700 (PDT) In-Reply-To: References: From: Andriy Berestovskyy Date: Wed, 11 May 2016 15:44:50 +0200 Message-ID: To: "Pavey, Nicholas" Cc: "users@dpdk.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [dpdk-users] Unable to see incoming packets with example KNI application X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 May 2016 13:45:11 -0000 Hi Nicholas, Those two lines look suspicious: ifconfig vEth0_0 172.25.48.200 ifconfig vEth1_0 172.25.48.201 Those lines configure two interfaces in the same class B network. Could it be the reason for the issues? Also, do you see the correct ARP entries on both sides? Andriy On Tue, May 10, 2016 at 7:58 PM, Pavey, Nicholas wrote: > Good afternoon, > > I=E2=80=99m a new user of the DPDK library - this is my first post to thi= s list. > > I=E2=80=99ve been experimenting with the various example applications, in= cluding =E2=80=98skeleton=E2=80=99 and =E2=80=98kni=E2=80=99. > > I have been able to get =E2=80=98skeleton=E2=80=99 to work correctly, and= observed good forwarding performance from it. I have been unable to get = =E2=80=98kni=E2=80=99 to work however. > > The symptom appears to be that incoming packets are not received correctl= y and are not forwarded to the KNI stack. Likewise, it appears that outboun= d ICMP =E2=80=98ping=E2=80=99 packets sent via the traditional linux =E2=80= =98ping=E2=80=99 command on the KNI interface are not sent (see observation= s, below). > > I=E2=80=99ve searched the mail archives and have seen several people with= what sounds like similar problems. I don=E2=80=99t believe I saw a problem= resolution there, however. > > Here=E2=80=99s a fair amount of detail about my environment. Please let m= e know if I=E2=80=99m missing something - I=E2=80=99ll happily provide extr= a details. > > Does anyone have any suggestions about what might be going on here? > > Regards, > > > > Nick Pavey > > > > Networking environment > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > * DPDK machine has dual 10Gbps NICs > - Intel 82599EB 10Gbps NIC > * DPDK machine is directly connected to an Ixia load generator > - SFP+ Direct Attached Copper (DAC) cabling > - Running BreakingPoint load generation software > * The linux kernel is unaware of the 10Gbps interfaces, so the DPDK can= attach correctly > * The control interface is an Intel I350 1Gbps copper NIC > - This has a statically assigned IP address > - I control the machine through this NIC > > DPDK versions > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > I have tried the =E2=80=98kni=E2=80=99 application with two versions of t= he DPDK: > > * DPDK-16.04, unpacked from tarball > * DPDK cloned from git. Head commit is db340cf2ef71af231af67be8e42fd603= e4bab0ac > - "i40e: fix VLAN stripping from inner header=E2=80=9D by JingJing Wu= , 5/4/2016 > > Machine details > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > Intel(R) Xeon(R) CPU E5-2640 v3 @ 2.60GHz > > Dual socket, 8 core, hyperthreaded. 32 total execution contexts. > 64GB RAM > NICS are dual Intel 82599EB 10Gbps > > OS/compiler details > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > The machine is running a modified version of the Kernel. IIRC, it=E2=80= =99s derived from Ubuntu 12.04. > > The kernel version is reported as 3.14.43. Unfortunately I=E2=80=99m unab= le to detail all the modifications, but it=E2=80=99s probably fair to assum= e the kernel is roughly equivalent to 3.13.43. > > The compiler is GCC version 4.6.3. > > > KNI application startup > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > I have 384 (size chosen fairly arbitrarily) available huge pages, which s= eems to be enough to allow the =E2=80=98kni=E2=80=99 application to start u= p. > > I have built the =E2=80=98rte_kni=E2=80=99 kernel module on the DPDK targ= et machine. I load it with no arguments, and it loads without complaint. > > I=E2=80=99m invoking the =E2=80=98kni=E2=80=99 application as follows: > > ./build/kni -c 0xf0 -n 4 -- -P -p 0x3 --config=3D"(0,4,6,8),(1,5,7,9)" > > So, the =E2=80=98kni=E2=80=99 application is in Promiscuous mode. > > Once the application is started up, I set up two IP addresses for the KNI= interfaces > > ifconfig vEth0_0 172.25.48.200 > ifconfig vEth1_0 172.25.48.201 > > Both seem to initialize correctly, and the =E2=80=98kni=E2=80=99 applicat= ion notices that the NIC status has changed. > > > The =E2=80=98kni=E2=80=99 application seems to start up correctly. I=E2= =80=99m not getting any errors, but equally, I=E2=80=99m not seeing traffic= get routed into the Linux network stack as I=E2=80=99d expect. > > > Observations > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > I=E2=80=99ve done several tests: > > * Sent a low level of traffic from the Ixia (a few packets a second) > - The Ixia is directly connected, so the data is not going missing in= the networking infrastructure > - The =E2=80=98skeleton=E2=80=99 application works as expected, so th= e Ixia, the cabling and a good part of the DPDK appears to be working > - A =E2=80=98tcpdump=E2=80=99 on the relevant network interfaces show= s no incoming traffic > - Watching the incoming packet rate with =E2=80=98sar -n DEV 1 1000= =E2=80=99 shows the kernel seeing no incoming traffic on the DPDK interface= s > - The statistics from the =E2=80=98kni=E2=80=99 application show no i= nbound data > - A packet capture on the Ixia interface shows outbound packets but n= o return packets. > > * Started the =E2=80=98kni=E2=80=99 application and the Ixia, then atte= mpted to ping the Ixia > - In this case, the statistics from the =E2=80=98kni=E2=80=99 applica= tion do show the TX counters incrementing > - However, when I examine the Ixia=E2=80=99s packet capture, I see no= signs of =E2=80=98ping=E2=80=99 packets. > > > Dmesg contents > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > When I bring up the KNI interfaces, I get the following lines in the =E2= =80=98dmesg=E2=80=99 log: > > [71051.312668] KNI: /dev/kni opened > [71051.470926] KNI: Creating kni... > [71051.471280] KNI: tx_phys: 0x00000000375313c0, tx_q addr: 0xf= fff8800 > 375313c0 > [71051.471281] KNI: rx_phys: 0x000000003752f340, rx_q addr: 0xf= fff8800 > 3752f340 > [71051.471282] KNI: alloc_phys: 0x000000003752d2c0, alloc_q addr: 0xf= fff8800 > 3752d2c0 > [71051.471282] KNI: free_phys: 0x000000003752b240, free_q addr: 0xf= fff8800 > 3752b240 > [71051.471284] KNI: req_phys: 0x00000000375291c0, req_q addr: 0xf= fff8800 > 375291c0 > [71051.471285] KNI: resp_phys: 0x0000000037527140, resp_q addr: 0xf= fff8800 > 37527140 > [71051.471286] KNI: mbuf_phys: 0x000000083c27dec0, mbuf_kva: 0xf= fff8808 > 3c27dec0 > [71051.471287] KNI: mbuf_va: 0x00007fe07ce7dec0 > [71051.471287] KNI: mbuf_size: 2048 > [71051.471306] KNI: pci_bus: 03:00:00 > [71051.506633] uio_pci_generic 0000:03:00.0: (PCI Express:5.0GT/s:Width x= 8) > [71051.506981] a0:42:3f:29:b3:ae > [71051.507710] uio_pci_generic 0000:03:00.0 (unregistered net_device): MA= C: 2, P > HY: 0, PBA No: FFFFFF-0FF > [71051.508340] uio_pci_generic 0000:03:00.0 (unregistered net_device): En= abled F > eatures: RxQ: 1 TxQ: 1 > [71051.510093] uio_pci_generic 0000:03:00.0 (unregistered net_device): In= tel(R) > 10 Gigabit Network Connection > > [71051.668942] KNI: Creating kni... > [71051.669291] KNI: tx_phys: 0x0000000037522f40, tx_q addr: 0xf= fff880037522f40 > [71051.669292] KNI: rx_phys: 0x0000000037520ec0, rx_q addr: 0xf= fff880037520ec0 > [71051.669294] KNI: alloc_phys: 0x000000003751ee40, alloc_q addr: 0xf= fff88003751ee40 > [71051.669295] KNI: free_phys: 0x000000003751cdc0, free_q addr: 0xf= fff88003751cdc0 > [71051.669296] KNI: req_phys: 0x000000003751ad40, req_q addr: 0xf= fff88003751ad40 > [71051.669297] KNI: resp_phys: 0x0000000037518cc0, resp_q addr: 0xf= fff880037518cc0 > [71051.669297] KNI: mbuf_phys: 0x000000083c27dec0, mbuf_kva: 0xf= fff88083c27dec0 > [71051.669298] KNI: mbuf_va: 0x00007fe07ce7dec0 > [71051.669299] KNI: mbuf_size: 2048 > [71051.669306] KNI: pci_bus: 03:00:00 > [71051.669308] KNI: pci_bus: 03:00:01 > [71051.704749] uio_pci_generic 0000:03:00.1: (PCI Express:5.0GT/s:Width x= 8) > [71051.705096] a0:42:3f:29:b3:af > [71051.705824] uio_pci_generic 0000:03:00.1 (unregistered net_device): MA= C: 2, PHY: 0, PBA No: FFFFFF-0FF > [71051.706452] uio_pci_generic 0000:03:00.1 (unregistered net_device): En= abled Features: RxQ: 1 TxQ: 1 > [71051.708210] uio_pci_generic 0000:03:00.1 (unregistered net_device): In= tel(R) 10 Gigabit Network Connection > [74051.258432] KNI: Successfully release kni named vEth0_0 > [74054.324270] KNI: Successfully release kni named vEth1_0 > [74054.379908] KNI: /dev/kni closed > > --=20 Andriy Berestovskyy