From owner-freebsd-net@FreeBSD.ORG Thu Mar 21 13:57:13 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 3CBB352A for ; Thu, 21 Mar 2013 13:57:13 +0000 (UTC) (envelope-from ermal.luci@gmail.com) Received: from mail-qe0-f46.google.com (mail-qe0-f46.google.com [209.85.128.46]) by mx1.freebsd.org (Postfix) with ESMTP id 01B85A9C for ; Thu, 21 Mar 2013 13:57:12 +0000 (UTC) Received: by mail-qe0-f46.google.com with SMTP id a11so1788194qen.5 for ; Thu, 21 Mar 2013 06:57:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=PiRkDsAgric+9o+oGLMTiuGX/xBHWmNUVK/co/yZLg0=; b=LpSALldtXG2UG3vzaM8nGKonEaSeF/l1Smoap4OD55trlduNCr9aqhCIlXtQOnRR30 TpzpfZ8PKfuvcKzNa/P6hC2yfc/3i2hhpqRbkO3YQQInIyFVwEjTjU9+bKpD1AdUPVtW G9t6rX3r3LvrGp4NglX360P+BNZBE4hBrWSAWLA4tn4NUBPK07G21VOV0zoncfvIjWnh 3NezDJ0beW/lU4EcXfG32UHyr4RYxQd9L0yExmmdR/hUFziHKffIDWnsGJS+x2QJbaSE +5q/8HZcdnkXAUpgQvsXFEd2DdWqxtF5c9tRYwuQNwrh3zWWpsWzMB7+s7fQvseRM6eQ QJSg== MIME-Version: 1.0 X-Received: by 10.49.25.12 with SMTP id y12mr8989978qef.1.1363874226153; Thu, 21 Mar 2013 06:57:06 -0700 (PDT) Sender: ermal.luci@gmail.com Received: by 10.49.98.103 with HTTP; Thu, 21 Mar 2013 06:57:06 -0700 (PDT) In-Reply-To: <96327F03-86EC-4EE6-9679-F66A960BDDB4@my.gd> References: <20130321005959.98706.qmail@f5-external.bushwire.net> <96327F03-86EC-4EE6-9679-F66A960BDDB4@my.gd> Date: Thu, 21 Mar 2013 14:57:06 +0100 X-Google-Sender-Auth: 5Y8n3icMM4eITLNNmk7sjFBZLDM Message-ID: Subject: Re: Best way for an app to accept traffic on 30,000+ interfaces? From: =?ISO-8859-1?Q?Ermal_Lu=E7i?= To: Fleuriot Damien Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: freebsd-net 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: Thu, 21 Mar 2013 13:57:13 -0000 On Thu, Mar 21, 2013 at 2:54 PM, Fleuriot Damien wrote: > > On Mar 21, 2013, at 9:25 AM, Ermal Lu=E7i wrote: > > > On Thu, Mar 21, 2013 at 1:59 AM, Mark D >wrote: > > > >> (Hopefully this isn't too out-of-scope for this list..) > >> > >> I have an application in mind that I'd like to have accept/respond to > >> UDP queries sent to perhaps 30K contiguous IP addresses (most likely > >> IPV6 addresses because such ranges are easy to come by, but > >> conceptually ipv4 as well). > >> > >> This would all be on a small number of FBSD instances. > >> > >> Though it could be done, I don't really want to create 30K interfaces > >> and have the application bind 30K sockets as it's not clear if that > >> will scale if I try an address range that expands to, say, 1M IPs > >> wide. > >> > >> This address range would be internet-facing and responding to random > >> remote clients. > >> > >> My first thought is to use SOCK_RAW in much the same way that natd > >> does - at least to receive the traffic. > >> > >> Is that a sensible and viable approach or is there a better/easier > >> way? > >> > >> > >> Mark. > >> _______________________________________________ > >> freebsd-net@freebsd.org mailing list > >> http://lists.freebsd.org/mailman/listinfo/freebsd-net > >> To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org" > >> > > > > > > How about firing up one of the firewall/pfil(9) consumers like (ipfw/pf= ) > > and adding rules to redirect traffic to a socket bound on loopback? > > > > -- > > Ermal > > > I fail to see how that's different from what I suggested with PF's rdr > rule ? > > I never saw the e-mail in this thread! --=20 Ermal