From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 35F27A0471 for ; Thu, 20 Jun 2019 21:22:07 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 03CCF1D4A0; Thu, 20 Jun 2019 21:21:21 +0200 (CEST) Received: from mail-pf1-f196.google.com (mail-pf1-f196.google.com [209.85.210.196]) by dpdk.org (Postfix) with ESMTP id ABC0B1D472 for ; Thu, 20 Jun 2019 21:21:06 +0200 (CEST) Received: by mail-pf1-f196.google.com with SMTP id m30so2198930pff.8 for ; Thu, 20 Jun 2019 12:21:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zwcpHj9mObwR/3WCwV5l4XnojjP3r4EDgCtfcfF1G0s=; b=P0f3TAMc+DtV27ziIjT/x2fHZI/kML1c8dumU50OimgpK6thLmbBsL6W+6AQJQInEi GS2JD/vfH+O9se0/RJmk5pgh0QWhTVglXNq64px6olt+1q4W4hTuRywnTZkOVpMcx2zH 2VGIm32JPwqPQI5tFjphX+iYQu1Q/pIWNFpYWovUGR3bcBeN7sY3sPpheRYTrS6RkHoj 7gBDLCSXZ86UH5JOITj1bkf1MdqZi0pJRJMxdXH5EHrMlqX3Q9Ra7v/35olXVjROEH2L 7wmlk4Fhwuyw/BQTnxQDy7OdbXLAtXTWumI2hao/7jlDDOujgi2hHSpESnQ3F/qfBsl1 zIdw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zwcpHj9mObwR/3WCwV5l4XnojjP3r4EDgCtfcfF1G0s=; b=NGILB65jcmvo2VRU8kWTxPXdy46AhwZ5WasQ3soa/d6fXOR8ufMLF/6eLBoIz3qwW+ zKGXQBZ3MRzQRrJTnSyNPQjs8wbbxsTj1x/Qq1bjPceUs/wJThAdQ7v22fSDMfm0jU3L yK3vuMQL7gdwdtpwdWf9NKMMfi1ozlidfdEa0uDcxcsLYr/sT3VIPlDuB3CQYIxk3LUJ CGg7xwIchXJ/u3cFMOMvDk7CTx5YUsRs8JBX91mxGkcFtnPq77Vqrlcx8iijOx1jH78x 2CAfJwiMcryxsn+hF/g49SizhxQRP59hLL7HN9E+x6qpdnxPzacmVlR9at10AchjS4ac ibXg== X-Gm-Message-State: APjAAAXvuewsJkWK8ba6v4QDzB3E8bmFWURPB6i+hgM2ela9ttLjxsVn 3SfOMRjzSLhOgGbZMfF0pR11WLhmSyE= X-Google-Smtp-Source: APXvYqyq+NNzBIz/Ffmz1xff1hv6kcr2w8084y5AJAIRTq6UU6ln5xrJOAiaO8bSBkybqVbDHfa5Xg== X-Received: by 2002:a63:2a0f:: with SMTP id q15mr14529539pgq.163.1561058465455; Thu, 20 Jun 2019 12:21:05 -0700 (PDT) Received: from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id j11sm255703pfa.2.2019.06.20.12.21.04 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Thu, 20 Jun 2019 12:21:04 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Date: Thu, 20 Jun 2019 12:20:46 -0700 Message-Id: <20190620192048.13814-8-stephen@networkplumber.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190620192048.13814-1-stephen@networkplumber.org> References: <20190610175155.21374-1-stephen@networkplumber.org> <20190620192048.13814-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v5 7/9] doc: update KNI documentation X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" Make the KNI documentation reflect modern kernel networking. Ifconfig has been superseded by iproute2 for 15 years. Iproute2 is well maintained, supports current feature set. Ethtool is no longer supported by KNI. Tshark is a better replacement for tcpdump. Signed-off-by: Stephen Hemminger --- .../sample_app_ug/kernel_nic_interface.rst | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/doc/guides/sample_app_ug/kernel_nic_interface.rst b/doc/guides/sample_app_ug/kernel_nic_interface.rst index a7e549d5213a..422bd8c98465 100644 --- a/doc/guides/sample_app_ug/kernel_nic_interface.rst +++ b/doc/guides/sample_app_ug/kernel_nic_interface.rst @@ -21,14 +21,14 @@ The FIFO queues contain pointers to data packets in the DPDK. This: * Provides a faster mechanism to interface with the kernel net stack and eliminates system calls -* Facilitates the DPDK using standard Linux* userspace net tools (tcpdump, ftp, and so on) +* Facilitates the DPDK using standard Linux* userspace net tools (tshark, rsync, and so on) * Eliminate the copy_to_user and copy_from_user operations on packets. The Kernel NIC Interface sample application is a simple example that demonstrates the use of the DPDK to create a path for packets to go through the Linux* kernel. This is done by creating one or more kernel net devices for each of the DPDK ports. -The application allows the use of standard Linux tools (ethtool, ifconfig, tcpdump) with the DPDK ports and +The application allows the use of standard Linux tools (iproute, tshark) with the DPDK ports and also the exchange of packets between the DPDK application and the Linux* kernel. The Kernel NIC Interface sample application requires that the @@ -220,13 +220,13 @@ Enable KNI interface and assign an IP address: .. code-block:: console - # ifconfig vEth0_0 192.168.0.1 + # ip addr add dev vEth0_0 192.168.0.1 Show KNI interface configuration and statistics: .. code-block:: console - # ifconfig vEth0_0 + # ip -s -d addr show vEth0_0 The user can also check and reset the packet statistics inside the ``kni`` application by sending the app the USR1 and USR2 signals: @@ -234,16 +234,16 @@ application by sending the app the USR1 and USR2 signals: .. code-block:: console # Print statistics - # kill -SIGUSR1 `pidof kni` + # pkill -USR1 kni # Zero statistics - # kill -SIGUSR2 `pidof kni` + # pkill -USR2 kni Dump network traffic: .. code-block:: console - # tcpdump -i vEth0_0 + # tshark -n -i vEth0_0 The normal Linux commands can also be used to change the MAC address and MTU size used by the physical NIC which corresponds to the KNI interface. @@ -254,13 +254,13 @@ Change the MAC address: .. code-block:: console - # ifconfig vEth0_0 hw ether 0C:01:02:03:04:08 + # ip link set dev vEth0_0 lladdr 0C:01:02:03:04:08 Change the MTU size: .. code-block:: console - # ifconfig vEth0_0 mtu 1450 + # ip link set dev vEth0_0 mtu 1450 When the ``kni`` application is closed, all the KNI interfaces are deleted from the Linux kernel. -- 2.20.1