From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 32D2DA034F; Mon, 22 Feb 2021 16:54:00 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 30DE91CC56E; Mon, 22 Feb 2021 16:53:55 +0100 (CET) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 25D181CC564 for ; Mon, 22 Feb 2021 16:53:53 +0100 (CET) IronPort-SDR: eq+69Z/zneVD/A8Dopdbnv6XruF52ZX5n7kHbWpQ9xfghe4LWeCoaOR2tfU6asxw/jJwFokyK+ ejzOoz4sNN2w== X-IronPort-AV: E=McAfee;i="6000,8403,9903"; a="164328298" X-IronPort-AV: E=Sophos;i="5.81,197,1610438400"; d="scan'208";a="164328298" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Feb 2021 07:53:41 -0800 IronPort-SDR: 4x/ZRE4RC611JHz0vUHq6uJcSCdlf1F6w+2xzUzJUvVcc6qAAx8OEnarlCIalDukHiFWgLa8Bx eCnUy8jU6q6g== X-IronPort-AV: E=Sophos;i="5.81,197,1610438400"; d="scan'208";a="498604790" Received: from mukeshku-mobl.gar.corp.intel.com (HELO [10.213.216.168]) ([10.213.216.168]) by fmsmga001-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Feb 2021 07:53:41 -0800 To: "mirzaei.reza" , dev@dpdk.org References: <82e2f6baea18519e8ee903e435c97af5@ut.ac.ir> From: Ferruh Yigit Cc: Dan Gora X-User: ferruhy Message-ID: Date: Mon, 22 Feb 2021 15:53:37 +0000 MIME-Version: 1.0 In-Reply-To: <82e2f6baea18519e8ee903e435c97af5@ut.ac.ir> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] dpdk_21.02--kni interface does not work properly X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 2/21/2021 9:45 AM, mirzaei.reza wrote: > Hello, > > I've recently migrated from dpdk-18.05 to dpdk-21.02. I built "kni" > example according to this tutorial [1 [1]], every thing is fine except > that > it has no output packet (no tx). There is a same problem in dpdk-20.11. > Have I ignored something? I would be > grateful if anyone could help me. > > It may also be helpful to mention that after I change the Interface > state to UP, The output of `ip link` shows that the state of this > interface still is DOWN. > It can be related to the 'carrier' update for the kni interfaces [1]. Can you please check following for your interface '': "cat /sys/class/net//carrier" There are a few options, - insert 'rte_kni.ko' kernel module with "carrier=on" kernel param, to default enable the carrier. "insmod ./build/kernel/linux/kni/rte_kni.ko carrier=on" - use '-m' argument to 'dpdk-kni' sample app, to reflect actual device carrier status to the kni interface: ./build/examples/dpdk-kni -l0,40-44 -- -m -P -p0x3 --config "(0,40,42),(1,41,43)" [1] Fixes: 89397a01ce4a ("kni: set default carrier state of interface") > outputs: > >> ./BUILD/KNI -L 4-7 -N 4 -- -P -P 0X3 --CONFIG="(0,4,6),(1,5,7)" > ------------------------------------------------------------------------------------------------------------ > > EAL: Detected 16 lcore(s) > EAL: Detected 1 NUMA nodes > EAL: Multi-process socket /var/run/dpdk/rte/mp_socket > EAL: Selected IOVA mode 'PA' > EAL: No available hugepages reported in hugepages-1048576kB > EAL: Probing VFIO support... > EAL: VFIO support initialized > EAL: using IOMMU type 1 (Type 1) > EAL: Probe PCI driver: net_i40e (8086:158b) device: 0000:06:00.0 (socket > 0) > EAL: Probe PCI driver: net_i40e (8086:158b) device: 0000:06:00.1 (socket > 0) > EAL: No legacy callbacks, legacy socket not created > APP: Initialising port 0 ... > APP: Initialising port 1 ... > > Checking link status > ........done > Port 0 Link up at 10 Gbps FDX Autoneg > Port 1 Link up at 10 Gbps FDX Autoneg > APP: ======================== > APP: KNI Running > APP: kill -SIGUSR1 128701 > APP: Show KNI Statistics. > APP: kill -SIGUSR2 128701 > APP: Zero KNI Statistics. > APP: ======================== > APP: Lcore 5 is reading from port 1 > APP: Lcore 6 is writing to port 0 > APP: Lcore 7 is writing to port 1 > APP: Lcore 4 is reading from port 0 > APP: Configure network interface of 0 up > KNI: Configure promiscuous mode of 0 to 1 > KNI: Configure promiscuous mode of 0 to 0 > > -------------------------------------------------------------------------------------------------------------- > > >> IFCONFIG VETH0 1.1.2.39/24 UP > >> TCPDUMP -V -N -I VETH0 > ------------------------------------------------------------------------------------------------------------ > > 07:22:26.218095 IP (tos 0x0, ttl 64, id 15551, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 1, length 64 > 07:22:27.218093 IP (tos 0x0, ttl 64, id 15619, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 2, length 64 > 07:22:28.242082 IP (tos 0x0, ttl 64, id 15826, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 3, length 64 > 07:22:29.266097 IP (tos 0x0, ttl 64, id 15948, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 4, length 64 > 07:22:30.290083 IP (tos 0x0, ttl 64, id 16060, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 5, length 64 > 07:22:31.314073 IP (tos 0x0, ttl 64, id 16118, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 6, length 64 > 07:22:32.342079 IP (tos 0x0, ttl 64, id 16236, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 7, length 64 > 07:22:33.366074 IP (tos 0x0, ttl 64, id 16332, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 8, length 64 > 07:22:34.390079 IP (tos 0x0, ttl 64, id 16511, offset 0, flags [DF], > proto ICMP (1), length 84) > 1.1.2.2 > 1.1.2.39: ICMP echo request, id 229, seq 9, length 64 > > -------------------------------------------------------------------------------------------------------------- > > Best Regards > > Links: > ------ > [1] > https://doc.dpdk.org/guides-21.02/sample_app_ug/kernel_nic_interface.html > [1] > > Links: > ------ > [1] > https://doc.dpdk.org/guides-20.11/sample_app_ug/kernel_nic_interface.html >