From owner-freebsd-net@FreeBSD.ORG Tue Jul 23 19:38:55 2013 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 58D4C698 for ; Tue, 23 Jul 2013 19:38:55 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wi0-x22f.google.com (mail-wi0-x22f.google.com [IPv6:2a00:1450:400c:c05::22f]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E10C02142 for ; Tue, 23 Jul 2013 19:38:54 +0000 (UTC) Received: by mail-wi0-f175.google.com with SMTP id m6so3444486wiv.8 for ; Tue, 23 Jul 2013 12:38:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=ezqOc6NI+WAZxsayIH4buImAKzlGLQda/lbydjD6X6I=; b=iLHMH5ZTZV0IK0H1BTAvnf+kSaaDLye8sVdTfBsMMMcRTsR0vQ1eRKsCDhNK7SpxIE nxqyslK24XCIwR5GrkCVrU131iyesAJf/HK9mxt1b6/3B2zo+pAGJ/LACC9n8amwi0tE 0FXSXj40dyTaBg+glbSiLWqijhXmoxBRMf1ztymQ/OWzz7iQhWLxvDwG/mNk5KfFjQ2U YjsVD1HyglIioxDr5wQWLmhRjUvzpdDPxdEgHtGnttyaHG0iV6vUyADjokmEYYC0cNxf MkajV4HN66tO+O3eiRFwDnhoPTZuBkoTOjyfAOE3v3fhRkowi9Ys7iI2k2ucVlhkQxM/ C59A== MIME-Version: 1.0 X-Received: by 10.194.92.6 with SMTP id ci6mr139175wjb.79.1374608333136; Tue, 23 Jul 2013 12:38:53 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.217.94.132 with HTTP; Tue, 23 Jul 2013 12:38:53 -0700 (PDT) In-Reply-To: <51EEC361.9050806@mail.ru> References: <51E0E2AF.7090404@mail.ru> <51E44E2F.8060700@mail.ru> <51E455D5.2090403@mail.ru> <20130722200205.GO26412@funkthat.com> <51EDA37A.9040200@mail.ru> <51EE198B.7040509@mail.ru> <51EE2C2B.4020800@mail.ru> <51EEC361.9050806@mail.ru> Date: Tue, 23 Jul 2013 12:38:53 -0700 X-Google-Sender-Auth: m4LUfvW5Q1GRRww1bk979bHcDbs Message-ID: Subject: Re: SO_REUSEPORT: strange kernel balancer behaviour From: Adrian Chadd To: trafdev Content-Type: text/plain; charset=ISO-8859-1 Cc: Sepherosa Ziehau , freebsd-net@freebsd.org, John-Mark Gurney X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Jul 2013 19:38:55 -0000 On 23 July 2013 10:54, trafdev wrote: > Yes, and if you kill this first thread - second thread will start to receive > connections and so on. > That's why I've used one processes-shared acceptor socket which behaves > better (load is balancing > between processes but equality of distribution is far from ideal). > > Btw as per https://lwn.net/Articles/542629/ Linux 3.1 SOLVES all these > problems via SO_REUSEPORT. Right, but the patch totally rewrites what SO_REUSEPORT means. I'd like to see similar behaviour in FreeBSD, but under a different socket option name. -adrain