From owner-freebsd-net@freebsd.org Fri Jul 10 15:27:28 2020 Return-Path: Delivered-To: freebsd-net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 95D7A36C444 for ; Fri, 10 Jul 2020 15:27:28 +0000 (UTC) (envelope-from cristian.cardoso11@gmail.com) Received: from mail-ej1-x62a.google.com (mail-ej1-x62a.google.com [IPv6:2a00:1450:4864:20::62a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4B3H3M4RxLz4kbx for ; Fri, 10 Jul 2020 15:27:27 +0000 (UTC) (envelope-from cristian.cardoso11@gmail.com) Received: by mail-ej1-x62a.google.com with SMTP id lx13so6525100ejb.4 for ; Fri, 10 Jul 2020 08:27:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=5szIIaA5Qqh/zEGo695hFkuRBxCyhaV5fvyXk1i6BQk=; b=iaiPL3xyp93UC3NT7PZq1D4cAOGSvxQLlOZOOYgUi89MAPHaxsG5BVeoIo/40Jtp+J KFqWLEpY6jBJ/kulkZSm469PvtF9EK6JFs3ZTynmN/TprSTIVUfA+b9+dj4AWQy08zkS YWEdSHsgJ0xOtuKuRJLVkFofANocD6ZXHuW3VeX658US0dc4+78qkQTabSkAet6jd2lW QH/evJ6lCuQWCTtHsTUQ29CcdO8v1/i1koJWvV29Wp8aZOELEIvxHPJQe8mwfeJnm+6X J9n2vP8kSMIGyx2/E4hjXCLUkXZs6BXOzn0yau8iwK8+J4z/GopJNKBr2nxyH6WOR3jr E1YQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=5szIIaA5Qqh/zEGo695hFkuRBxCyhaV5fvyXk1i6BQk=; b=DBHjqlnLTPAEd89f7+NKK/MWrR5seMQsU0MklUYmiU0dKihqrKDcsOV34mQ0hRHDkO qoRTjuPy2JSIxeZWt/1B9KSHWKcy7GdPSomgTLXEWiPIZVcykt1FNEmvChTjFu1MsyIe 6pjZK7HU7HQSyH+9bU2duLExSG6oELI1uyBMQyO+Nv8x/uqHbpToU2M8rnBjp+MkAoVy OTapRLhVqsKbHyfCLb6a0bC/Mfj7tvW/XIDPvTlCt+DMRM9faAAxjHiLSKEL0RTFredY +fdRXyZXY2iHyvjcckAwYcy0LrCUjwdUnimS2UeYYxGBEfTOH+UQXByRS48tdQfO6eRr gAMw== X-Gm-Message-State: AOAM5316WN7hgKKN5Vbuhlk4/uQylT0dhAydTfO8ozDoJFZoCRl1+vak mufsxk2154MYRZkCuGvY+eRVSAeKxmaYzZYZMSbBI+IpZA== X-Google-Smtp-Source: ABdhPJyWGXLqelAHEKFWEpYsLabeXUbTwXWvp3GmRfP9MHQDzZxEMRXkRpVYX+zWD/zjEk5lKl+N9eOezq7Ps/QOXCM= X-Received: by 2002:a17:907:20b4:: with SMTP id pw20mr63871193ejb.225.1594394845636; Fri, 10 Jul 2020 08:27:25 -0700 (PDT) MIME-Version: 1.0 References: <20200710084530.777ce321@mr185033.univ-rennes1.fr> In-Reply-To: <20200710084530.777ce321@mr185033.univ-rennes1.fr> From: Cristian Cardoso Date: Fri, 10 Jul 2020 12:27:15 -0300 Message-ID: Subject: Re: poor performance with Intel X520 card To: Patrick Lamaiziere Cc: freebsd-net@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 4B3H3M4RxLz4kbx X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=iaiPL3xy; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of cristiancardoso11@gmail.com designates 2a00:1450:4864:20::62a as permitted sender) smtp.mailfrom=cristiancardoso11@gmail.com X-Spamd-Result: default: False [-3.13 / 15.00]; RCVD_TLS_ALL(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; NEURAL_HAM_MEDIUM(-0.99)[-0.995]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-net@freebsd.org]; NEURAL_HAM_LONG(-1.04)[-1.036]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::62a:from]; NEURAL_HAM_SHORT(-0.10)[-0.104]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; RCVD_COUNT_TWO(0.00)[2]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; TAGGED_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2020 15:27:28 -0000 Hello This interface is 14.8 Mpps, but such capacity is only possible without a firewall performing filtering. The more firewall rules on your router, the less forwarding capacity the card will have, due to having to process the packet in CPU to match the rules and then forward the packet. In the link that follows, a little is talked about: https://wiki.freebsd.org/NetworkPerformanceTuning Here are some more useful links on FreeBSD and network tuning https://calomel.org/freebsd_network_tuning.html https://people.freebsd.org/~olivier/talks/2017_EuroBSDCon-Tuning_FreeBSD_fo= r_routing_and_firewalling.pdf Em sex., 10 de jul. de 2020 =C3=A0s 03:45, Patrick Lamaiziere escreveu: > > Hello, > > That is mostly for the record but it looks like the intel X520 is not > very good and generates a high level of interrupts. > > On a router / firewall with 500 Kpps in input (dropped by pf) is enough t= o put the CPUs at > 100% busy. > > We use FreeBSD 11.3 on a machine with 12 CPU Intel(R) Xeon(R) CPU E5-2643= v3 @ 3.40GHz (3400.07-MHz K8-class CPU) > FreeBSD/SMP: Multiprocessor System Detected: 12 CPUs > FreeBSD/SMP: 2 package(s) x 6 core(s) > Multi threading is disabled. > > ix0: = port 0x3020-0x303f mem 0x92300000-0x923fffff,0x92404000-0x92407fff irq 34 a= t device 0.0 numa-domain 0 on pci5 > ix0: Using MSI-X interrupts with 9 vectors > ix0: Ethernet address: a0:36:9f:93:84:10 > ix0: PCI Express Bus: Speed 5.0GT/s Width x8 > ix0: netmap queues/slots: TX 8/2048, RX 8/2048 > > I've set fews tunable in loader.conf but I don't remember why > loader.conf > # cartes ix > #hw.ix.max_interrupt_rate=3D100000 > #hw.ix.enable_aim=3D0 > hw.ix.tx_process_limit=3D-1 > hw.ix.rx_process_limit=3D-1 > #hw.ix.num_queues=3D6 > hw.intr_storm_threshold=3D9000 > > Well, do you think another NIC cards can help to reach a better pps rate = ? I think 500 Kpps is quite low for such a machine. > > Thanks, best regards. > > _______________________________________________ > freebsd-net@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-net > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"