From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt1-x830.google.com (mail-qt1-x830.google.com [IPv6:2607:f8b0:4864:20::830]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.bufferbloat.net (Postfix) with ESMTPS id 6E7EA3B2A4 for ; Wed, 2 Jan 2019 22:57:04 -0500 (EST) Received: by mail-qt1-x830.google.com with SMTP id i7so35684530qtj.10 for ; Wed, 02 Jan 2019 19:57:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:subject:from:to:date:in-reply-to:references:user-agent :mime-version:content-transfer-encoding; bh=hnEdQRBnSo4wu8RQU+xVR3SWHQ+NGrWG2cLQyCNWb6s=; b=X8ZojkY0iNalfr0edWtODzy2/01c9WYWb0qlTxNVxb39t4zNBPbRs+lNvcttiNHwEv 8Rk4VOTrSCzcDYBa7FXFDLJQ5vBBwKDMVrpux985vI6h5qjm7tfI96v0eC+Hz9P2M/JP ayIDv97wGkCfGh2lR6r9ITaLkPgFgCVNeR98V2Q9EI4VTizat3ztdDokxFdQYW2S+Ggr ZjoyPsq1JEkbrSUHCReRx4dZ9vSYQySrc7SjvpM66YmOLn/TiLvdq2U33A1Ib7nG3Jqm vF7KItVqKQ9+fcczaPSz/tqK7TJE/FSBnDfCU+NJprrCovM0rvjkkrPqA9/EP+pGckON rOWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=hnEdQRBnSo4wu8RQU+xVR3SWHQ+NGrWG2cLQyCNWb6s=; b=ekN+f+LfSdeV1dAn0ZQnSnhK6Ezw5QlTuLu8VpcWbiiq8ZE3/0fqsNe042nVIZH/xA w9e9IRVP/0csJuXAsHp0fT2hjNMEhyDZDtQfK9I6JcwnARGdpwRgkH+Sy1lAN1mitlBH EUG+jdvwEvaFLXo/keNyoY9U6kTb9VTKSpw74KOpFfvx6dW5WTwZYn/g34iyAybxF0M6 m9a0Ltw+pTehKYOfEPGVZLy+lPMTAbwsrfpL3u/18+uene+SxM8Y+QeIDl4OUUQv5CtJ 6jdRgJvyywtZfHvjFymnlyagPT9UY7exvrpfvt+ioJnufS3cIlG56USfL1a8EkPWxwgL Mlww== X-Gm-Message-State: AA+aEWZcRtSBgh9MACN7rQAJdNrQX9eChIJ5QAb4kFSRxl0k/yyrN6q1 2MC9wChzzPsnz0rytpuYVyMdi5I2 X-Google-Smtp-Source: ALg8bN5XWBAVjo1GZtkqrX6nMV2rbfGdymODD5KyK1U61SH8f9bhscE4JJKO4uIZUPnv6BKi4KM7NQ== X-Received: by 2002:ac8:208a:: with SMTP id 10mr44636013qtd.79.1546487823754; Wed, 02 Jan 2019 19:57:03 -0800 (PST) Received: from x3200.lan ([2601:152:4302:ae1f::16e]) by smtp.googlemail.com with ESMTPSA id 83sm29699200qkz.73.2019.01.02.19.57.02 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 02 Jan 2019 19:57:03 -0800 (PST) Message-ID: <43a8ddec5beb962c53fe828363ecc839832de2c0.camel@gmail.com> From: Georgios Amanakis To: Pete Heist , Cake List Date: Wed, 02 Jan 2019 22:57:02 -0500 In-Reply-To: <8F9DE6A8-8614-46A8-9E9B-7B7E4CC7414F@heistp.net> References: <8F9DE6A8-8614-46A8-9E9B-7B7E4CC7414F@heistp.net> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.30.3 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: Re: [Cake] dual-src/dsthost unfairness, only with bi-directional traffic X-BeenThere: cake@lists.bufferbloat.net X-Mailman-Version: 2.1.20 Precedence: list List-Id: Cake - FQ_codel the next generation List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 03 Jan 2019 03:57:04 -0000 I can reproduce this one to my surprise, too. I tested on my Comcast connection, with a WRT1900ACS, running openwrt (r8082-95b3f8ec8d, 4.14.70), with two interfaces br-lan and eth0(wan). IP1=1 up / 8 down IP2=4 up / 4 down src/dst, bidir: IP1=0.88 / 8.44, IP2=0.66 / 7.75 (ok) dualsrc/dualdst, bidir: IP1=0.27 / 10.56, IP2=1.41 / 6.42 (unfair) No VLANs, no other schedulers on eth0 and br-lan apart from cake. On Wed, 2019-01-02 at 00:04 +0100, Pete Heist wrote: > In my one-armed router setup I’m seeing host fairness work perfectly > with srchost or dsthost, but with dual-srchost or dual-dsthost, host > fairness deviates from the ideal, _only_ when there's bi-directional > traffic. The deviation is then dependent on the number of flows. Is > this expected? > > I had thought that dual-src/dsthost worked the same as src/dsthost > (fairness between hosts) with the exception that there is also > fairness of flows within each host. > > Here are some results (all rates aggregate throughput in Mbit): > > IP1=8 up / 1 down IP2=1 up / 8 down (post-test tc stats attached): > srchost/dsthost, upload only: IP1=48.1, IP2=47.9 (OK) > srchost/dsthost, download only: IP1=47.8, IP2=47.8 (OK) > srchost/dsthost, bi-directional: IP1=47.5 up / 43.9 down, > IP2=44.7 up / 46.7 down (OK) > > dual-srchost/dual-dsthost, upload only: IP1=48.1, > IP2=48.0 (OK) > dual-srchost/dual-dsthost, download only: IP1=47.9, > IP2=47.9 (OK) > dual-srchost/dual-dsthost, bi-directional: IP1=83.0 up / 10.7 > down, IP2=10.6 up / 83.0 down (*** asymmetric ***) > > Dual-srchost/dual-dsthost, bi-directional tests with different flow > counts: > > IP1=4 up / 1 down IP2=1 up / 4 down: > IP1=74.8 up / 18.8 down, IP2=18.8 up / 74.8 down > > IP1=2 up / 1 down IP2=1 up / 2 down: > IP1=62.4 up / 31.3 down, IP2=31.3 up / 62.4 down > > IP1=4 up / 1 down IP2=1 up / 8 down: > IP1=81.8 up / 11.5 down, IP2=17.4 up / 76.3 down > > IP1=2 up / 1 down IP2=1 up / 8 down: > IP1=79.9 up / 13.5 down, IP2=25.7 up / 68.1 down > > The setup: > > apu2a (kernel 4.9) <— default VLAN —> apu1a (kernel > 3.16.7) <— VLAN 3300 —> apu2b (kernel 4.9) > > - apu1a is the router, and has cake only on egress of both eth0 and > eth0.3300, rate limited to 100mbit for both > - it has no trouble shaping at 100mbit up and down simultaneously, so > that should not be a problem > - the same problem occurs at 25mbit or 50mbit) > - since apu2a is the client [dual-]dsthost is used on eth0 and [dual- > ]srchost is used on eth0.3300 > - the fairness test setup seems correct, based on the results of most > of the tests, at least. > - note in the qdisc stats attached there is a prio qdisc on eth0 for > filtering out VLAN traffic so it isn’t shaped twice > - I also get the exact same results with an htb or hfsc hierarchy on > eth0 instead of adding a qdisc to eth0.3300 > - printk’s in sch_cake.c shows values of flow_mode, srchost_hash and > dsthost_hash as expected > - I also see it going into allocate_src and allocate_dst as expected, > and later ending up in found_src and found_dst > > I’m stumped. I know I’ve tested fairness of dual-src/dsthost before, > but that was from the egress of client and server, and it was on a > recent kernel. Time to sleep on it... > > _______________________________________________ > Cake mailing list > Cake@lists.bufferbloat.net > https://lists.bufferbloat.net/listinfo/cake