From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5FD0FA00C5; Mon, 6 Jul 2020 20:23:22 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id C25AC1DC09; Mon, 6 Jul 2020 20:23:21 +0200 (CEST) Received: from mail-pg1-f195.google.com (mail-pg1-f195.google.com [209.85.215.195]) by dpdk.org (Postfix) with ESMTP id C35DD1DC04 for ; Mon, 6 Jul 2020 20:23:20 +0200 (CEST) Received: by mail-pg1-f195.google.com with SMTP id m22so8390711pgv.9 for ; Mon, 06 Jul 2020 11:23:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=N7DChwmD3Jpb/g55xkxGoiATfD6Ckz2BS1gEnxTZe9s=; b=kj7UarJgDc42zOu7bpRuu3ilkjQcQQQdwb6RYCXY2PCMR7VHU8oNtAnvMMsnTFLcAT H20EZln13E8D1k0kVZW1x78E+WQKWP7f1HncfXFxSZUS0r/uq/sgxnE9jnyLWDmCSpaw crJmA13jxwpk2aI3ymRTeIoYn4z9U/fCp310ff3NE3IOO10bm1LwX49roR8RFkvqYlnA 1bxWFlZDvRAAy4baNDGvGtMFs4L7jX1xQtWdaHl9aDKuuPD9NrpArONTd9lP7LzbBt/7 ZV2x0QeCEgLORO/mUfuJglGWWsAcD4WTS2euT+rvVybi5C4CMvEj6FX/cigJyZdSxlk7 SxMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=N7DChwmD3Jpb/g55xkxGoiATfD6Ckz2BS1gEnxTZe9s=; b=JLcqMGDud0++Dba+KdMmHpwidqfdgPZL/vzI4CsQxw4nfYadXDps5e/iH+uFUN6YJa 3FeMxoA+BIR2XiZErPA+PSBNRN9rpWXvhy0o4TUH9UT1429lyzzBOmtj/ef+wUzoDw0h M7kne32QFLlO4tHEV+ivAjzbkMK37955kAXc28dXtR1mNp1mZslf91szpKAr0OztD0zC dtJMicHV26/RH7a3bXOdoRjEpk5MZwe+80EtKx631cSRC+N7LS6x+qYyd404RzbPMfC3 EibacQWB0Fivp1I0QUjFBNOmtZddEREVDhdImIUhC0w4ACeWMTN2WYJJ6DDB2TxvK+qU dj7Q== X-Gm-Message-State: AOAM532RqbTAzj5XhLCjNIqPPJR8+tbk6QsnqL+qRTOwY/EVz9nabk04 vP4zui/R3NnRkUUOBtwLGYepmw== X-Google-Smtp-Source: ABdhPJy1UTUhJxHEbL4OOM2MGb9b4z8qK5jBqttr9zEF2rYx2KeEp9LhGOzD2w5PO9kHVUrYGvjT+g== X-Received: by 2002:a63:6741:: with SMTP id b62mr40701170pgc.58.1594059799827; Mon, 06 Jul 2020 11:23:19 -0700 (PDT) Received: from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id i21sm4359648pfa.18.2020.07.06.11.23.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2020 11:23:19 -0700 (PDT) Date: Mon, 6 Jul 2020 11:23:11 -0700 From: Stephen Hemminger To: Jiawei Wang Cc: orika@mellanox.com, viacheslavo@mellanox.com, matan@mellanox.com, dev@dpdk.org, thomas@monjalon.net, rasland@mellanox.com, ian.stokes@intel.com, fbl@redhat.com Message-ID: <20200706112311.383ba6b2@hermes.lan> In-Reply-To: <1594057868-18724-1-git-send-email-jiaweiw@mellanox.com> References: <1593715390-83047-1-git-send-email-jiaweiw@mellanox.com> <1594057868-18724-1-git-send-email-jiaweiw@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v3 0/7] support the flow-based traffic sampling 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" On Mon, 6 Jul 2020 20:51:01 +0300 Jiawei Wang wrote: > This patch set implement the flow sampling for mlx5 driver. > > The solution is introduced a new rte_flow action that will sample the incoming traffic and send a duplicated traffic with the specified ratio to the application, while the original packet will continue to the target destination. > > If the sample ratio value be set to 1, means that the packets would be completely mirrored. The sample packet can be assigned with different set of actions from the original packet. > > MLX5 PMD driver will be responsible for validate and translate the sample action while creating a flow. > You seem to have ignored my feedback that this could be more useful if it didn't just support duplication. It should allow sampling and then make the other rule chain (the one that gets hit after sampling) run. By allowing a more general form of sampling it could be used for doing network emulation (or packet manipulation) as well as simple netflow/ipfix style sampling.