From owner-freebsd-net@freebsd.org Fri Jun 16 12:51:39 2017 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 002B9BFFDDA for ; Fri, 16 Jun 2017 12:51:38 +0000 (UTC) (envelope-from v.maffione@gmail.com) Received: from mail-oi0-x22b.google.com (mail-oi0-x22b.google.com [IPv6:2607:f8b0:4003:c06::22b]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B1D397DF0E; Fri, 16 Jun 2017 12:51:38 +0000 (UTC) (envelope-from v.maffione@gmail.com) Received: by mail-oi0-x22b.google.com with SMTP id k145so23544688oih.3; Fri, 16 Jun 2017 05:51:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=MFskJHhuYNWzxd0zS4XTrXgtihCvsy7gYSL8lTDEhOU=; b=AhDzzXoeRQCzAbZGeyY6C679IAnmUoxuQdCK9SdArCFj6gfq009xP7bfHHjhzJ5CPl c+TK1E/amyRY6FboO/mRD/3YcGji6P/evS2+2d7V39cywoRcZqzdzm4glCOMIdB637dq YG1jeMPdWkZeTpymk9rHZr3qkjeBGeGUxg5rxsis4KBX/Wjg/u3EnkQ6axFQA5fAs7rT FDnEyyxwEt8pvomJZ2H0JJrCaZwgkKW+/KSx0BASJG7jp41Jvcx7PUjf2zYkFQznzwTW nSVGatmPAlGB782wgMDx+TBeMAzIOoY43qYcrZFyfUDmNb5yTbiezvQ5NGpXN94nHQTy otfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=MFskJHhuYNWzxd0zS4XTrXgtihCvsy7gYSL8lTDEhOU=; b=KFN8KaQkvkf8dyj85ae2XnKguuk0oAEpgygMJ3NmB7e9N7C0H4t5zxGKTwOz0ODGzI 3ojRQTlIS9EIr2XtKzCpKo8zRYR8Xh9M/dD6NRu4rFeS7SwpV46DWtXntE5Ur2Uew/oO GFG5HPe0yVGxAqczBcTA6HouZebmwPpkiOagIVd4FdRdxf2Tbt5xC/rTaAG04pqjUIWr Ef8FtGdAJiVib6MdAGiysm2y9A2xya2dAeQ4xKB01t1vpTYgSOwg8bRQT3UoJ8xjMYP+ eAQUEVe8DjCyXw+sTDk7Kbx67phy1R8YQu5HW9uxzTZX36CQ+K8cOe0LypOIdsusYE16 TDRg== X-Gm-Message-State: AKS2vOyQmVf3L2/bZFjAwxpDsymmywKBYW75guyNYkLBYhhT/0IRNCgJ INf3rDtZLOVQZhioN4sGk08dUPSQMbpl X-Received: by 10.202.88.134 with SMTP id m128mr6208071oib.164.1497617497860; Fri, 16 Jun 2017 05:51:37 -0700 (PDT) MIME-Version: 1.0 Received: by 10.157.17.49 with HTTP; Fri, 16 Jun 2017 05:51:37 -0700 (PDT) In-Reply-To: References: <3b3ecffa-36e5-75b1-2b25-db9e9dcd45ba@gmail.com> From: Vincenzo Maffione Date: Fri, 16 Jun 2017 14:51:37 +0200 Message-ID: Subject: Re: state of packet forwarding in FreeBSD? To: Jordan Caraballo Cc: Navdeep Parhar , FreeBSD Net , =?UTF-8?Q?Olivier_Cochard=2DLabb=C3=A9?= , John Jasen Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.23 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, 16 Jun 2017 12:51:39 -0000 Also, there is a more basic problem. The bridge program requires physical interfaces to be specified with the "netmap:" prefix. For example: # ./bridge netmap:ix0 netmap:em2 # OK # ./bridge ix0 em2 # WRONG 2017-06-16 14:47 GMT+02:00 Vincenzo Maffione : > Some comments inline: > > 2017-06-16 14:13 GMT+02:00 Jordan Caraballo = : > >> Hi guys, >> >> We tried multiple attempts to implement netmap vale-ctl and bridge in >> chelsio vcxl* interfaces. The most interesting attempts, are mentioned >> below. >> >> First Attempt: Ran "./bridge vcxl0 vcxl1"; but it would complain about >> having a 0 burst size. Added "-b 1024" to the command as recommended by >> the log from the script, but the issue was still present. >> > > If > > # ./bridge ifname1 ifname2 > > doesn't work it means there is some problem with the driver the interface= s > are using. Default burst size used by "bridge" is already 1024. > You may try to repeat this experiment after setting "sysctl > dev.netmap.admode=3D2", to use the emulated mode, that is the legacy driv= er > (of course performance would be limited, but at least you check > functionality). > Check netmap(4) for more info. > > >> >> Second Attempt: Tried to combine vale-ctl and bridge by: >> # ./vale -h vale0:vcxl0 >> # ./vale -h vale0:vcxl1 >> # ./bridge vale0:1 vale0:3 > > >> There was no error, however, traffic did not flow at the time of >> shooting packets to the interfaces. >> > > What did you mean to do here? This setup creates a forwarding loop > involving the VALE switch "vale0" and the userspace hub implemented by > "bridge". > I'm not surprised that you see nothing.. > > >> >> Third Attempt: By following this email >> threadhttps://lists.openinfosecfoundation.org/pipermail/ >> oisf-users/2015-October/005310.html; >> we ran: >> # ./vale-ctl -n b0 >> # ./vale-ctl -n b1 >> # ./vale-ctl -a vale0:b0 >> # ./vale-ctl -a vale0:vcxl0 >> # ./vale-ctl -a vale1:b1 >> # ./vale-ctl -a vale1:vcxl1 >> # ./bridge -i netmap:vcxl0 -i netmap:vcxl1 >> >> Same result as before, no errors, yet no traffic in the interfaces. >> >> > This should throw errors, as you are first attaching vcxl0 to a VALE > switch, and then opening vclx0 in netmap mode with the bridge program: > netmap forbids you to do that, because when an interface is attached to a > VALE switch it is "busy", and cannot be opened again from another netmap > application (like bridge). > Same reasoning for vcxl1. > > Have you tried with the basic TX/RX tests first, without involving VALE? > > # pkt-gen -i netmap:vcxl0 -f tx > # pkt-gen -i netmap:vcxl0 -f rx > > > Regards, > Vincenzo > > >> Any feedback or advice on why traffic is not flowing? >> >> We would like to note that throwing packets to the vcxl interfaces >> without any netmap aware application ranges from 1.1M to 1.2M pps. >> >> Is this supposed to happen? (We consider that still, the number is quite >> low) >> >> - Jordan >> >> >> 2017-06-15 17:15 GMT-04:00 Navdeep Parhar : >> >> > On 06/14/2017 10:42, Olivier Cochard-Labb=C3=A9 wrote: >> > >> >> On Wed, Jun 14, 2017 at 7:36 PM, Navdeep Parhar > >> > wrote: >> >> >> >> >> >> I think I fixed this a long time back. Have you tried recently? >> We >> >> moved the netmap functionality to the vcxl interfaces and it shou= ld >> >> just work. >> >> >> >> =E2=80=8B >> >> It stills panic with an -head build today. >> >> >> >> >> > Fixed in r319986. >> > >> > >> > _______________________________________________ >> > 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" >> > >> >> >> >> -- >> Jordan >> _______________________________________________ >> 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" >> > > > > -- > Vincenzo Maffione > --=20 Vincenzo Maffione