Souji Thenria

FreeBSD VM Network Issues

Summary: Strange networking issues when running FreeBSD as VM and using the VirtIO Ethernet driver.

Created on:

-----

In case you ever run FreeBSD as a virtual machine and observe strange networking issues that you cannot explain, chances are that you are experiencing problems with the VirtIO Ethernet driver (VTNET(4)).

How do you know that you are using that driver? Just look at the interface name, if it is something like vtnet0, you are using the driver.

Most of the time, for me, the issue was checksum offloading to the network card. However, since then, I have decided to disable any kind of offloading to the network card in the driver. The performance penalty of doing that is negligible for my use cases.

In order to disable any offloading, you can add the following to your loader.conf(5):

hw.vtnet.csum_disable=1
hw.vtnet.tso_disable=1
hw.vtnet.lro_disable=1
hw.vtnet.mq_disable=1
Tags: