09.12.2017

Installing netmap module for FreeBSD kernel

Installing netmap module for FreeBSD kernel
Try to build kernel module for current kernel:

cd /usr/src/sys/modules/netmap<br>
make <br>
make install<br>
kldload netmap

But you could hit this bug:

KLD netmap.ko: depends on kernel – not available or version mismatch linker_load_file: Unsupported file type

Enable netmap startup on server load:

echo 'netmap_load="YES"' >> /boot/loader.conf

To activate Netmap on your server you have to turn your interface on promiscuous mode: ifconfig promisc

And should rebuild kernel manually.

Install SVN:

pkg install devel/subversion

Download base repository for FreeBSD 10 stable (replace 10 by your FreeBSD version):

svn checkput https://svn0.ru.freebsd.org/base/stable/10 /usr/src

Build and install new kernel:

cd /usr/src/sys/amd64/conf<br>
cp GENERIC KERNELWITHNETMAP<br>
cd /usr/src<br>
make buildkernel KERNCONF=KERNELWITHNETMAP<br>
make installkernel KERNCONF=KERNELWITHNETMAP