Date: Wed, 28 Mar 2018 15:26:44 +0000 From: Vincenzo Maffione <v.maffione@gmail.com> To: Ming Fu <Ming.Fu@esentire.com> Cc: FreeBSD Net <freebsd-net@freebsd.org> Subject: Re: Netmap on Linux nm_open() fail when receive ring size is set to 4096 Message-ID: <CA%2B_eA9jk53Z8YgaqNaQEdYuZApKg3L7YXwHdG4gqu3pst3YCSw@mail.gmail.com> In-Reply-To: <092c8d937ff6471fb701d64dcff1c756@mbx01cmb01p.esentire.local> References: <092c8d937ff6471fb701d64dcff1c756@mbx01cmb01p.esentire.local>
next in thread | previous in thread | raw e-mail | index | archive | help
Hi, You need to increase the value of some netmap module parameter. At least ring_size, maybe also buf_num. Then restart your netmap applications. Keep in mind that performance could worsen with more slots, because of increased cache thrashing. Cheers, Vincenzo On Wed, Mar 28, 2018, 3:50 PM Ming Fu <Ming.Fu@esentire.com> wrote: > Hi, > > I was trying netmap on a Linux box with 128G of ram (64G per numa node). > If I set ixgbe interface to 4096 ring size, the nm_open will fail with > error "Cannot allocate memory". What can I tweak to make the card use > larger ring size? The following test was run after fresh reboot. > > $ ethtool -g enp5s0f0 > Ring parameters for enp5s0f0: > Pre-set maximums: > RX: 4096 > RX Mini: 0 > RX Jumbo: 0 > TX: 4096 > Current hardware settings: > RX: 512 > RX Mini: 0 > RX Jumbo: 0 > TX: 512 > > $ ethtool -G enp5s0f0 rx 1024 > $ ./nmtest -i enp5s0f0 > ^C > $ ethtool -G enp5s0f0 rx 2048 > $ nmtest -i enp5s0f0 > ^C > $ ethtool -G enp5s0f0 rx 4096 > $ nmtest -i enp5s0f0 > 816.039684 nm_open [945] NIOCREGIF failed: Cannot allocate memory > netmap:enp5s0f0 > fail to nm_open(netmap:enp5s0f0 ... ): Cannot allocate memory > > Thanks, > Ming > _______________________________________________ > 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" >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2B_eA9jk53Z8YgaqNaQEdYuZApKg3L7YXwHdG4gqu3pst3YCSw>