Re: FBSD-13 - Vale maximum virtual switches.
- In reply to: Vincenzo Maffione : "Re: FBSD-13 - Vale maximum virtual switches."
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 03 Mar 2022 22:06:32 UTC
Thanks a lot Vincenzo.
Santi
On 3/3/22 23:03, Vincenzo Maffione wrote:
> Hi,
> Yes, the maximum number of VALE bridges should definitely become a
> sysctl.
> I'll try to implement the change asap.
>
> Cheers,
> Vincenzo
>
> Il giorno gio 3 mar 2022 alle ore 19:07 Santiago Martinez
> <sm@codenetworks.net> ha scritto:
>
> Hi Everyone,
>
> The other day had to simulate a network topology and I wanted to
> use vale switches instead of in-kernel bridges.
>
> After creating a few switches I notice that there was a hard limit
> of 8 switches ( that is clearly stated on the man page).
>
> For my simulation I needed 32 virtual switches, hence I increase
> the value of NM_BRIDGES from 8 to 64.
>
> After that I was able to create the bridges and they seem to work
> fine.
>
> My question is, do we need that hard limit on 8? Should this be
> change to a dynamic value set with sysctl?
>
> Best regards.
> Santi
>
> diff --git a/sys/dev/netmap/netmap_bdg.h b/sys/dev/netmap/netmap_bdg.h
>
> index e4683885e66c..3afe1d9d5d99 100644
> --- a/sys/dev/netmap/netmap_bdg.h
> +++ b/sys/dev/netmap/netmap_bdg.h
> @@ -73,8 +73,8 @@struct netmap_bdg_ops {
> int netmap_bwrap_attach(const char *name, struct netmap_adapter *,
> struct netmap_bdg_ops *);
> int netmap_bdg_regops(const char *name, struct netmap_bdg_ops
> *bdg_ops, void *private_data, void *auth_token);
>
> -#define NM_BRIDGES 8 /* number of
> bridges */
> -#define NM_BDG_MAXPORTS 254 /* up to 254 */
> +#define NM_BRIDGES 64 /* number of
> bridges */
> +#define NM_BDG_MAXPORTS 16 /* up to 254 */
> #define NM_BDG_BROADCAST NM_BDG_MAXPORTS
> #define NM_BDG_NOPORT (NM_BDG_MAXPORTS+1)
>
>
>