I just started learning how to use Qemu for a project. I was trying to run Qemu using using bridge networking and was wondering what is the difference between the network options, tap and bridge.
I read the network options part in the Qemu document but is unable to understand the difference. The document mention that "-netdev tap" is use to configure a host TAP network backend with ID id while "-netdev bridge" is use to connect a host TAP network interface to a host bridge device. I also look at this website: https://wiki.archlinux.org/title/QEMU#Tap_networking_with_QEMU, but was still unable to understand the difference between using "-netdev tap" vs "-netdev bridge".
Can anyone help me by explaining the differences between using "-netdev tap" and "-netdev bridge" for Qemu?
Thank you.
They both provide different command line interfaces to use TAP as the network backend for the guest to connect to a host bridge. The TAP netdev allows for a finer degree of control of the TAP device that is used but in both cases the network path is the same. This is in contrast to user-mode networking which allows networking without privileged access to the host network stack albeit with some limitations on the sort of packets that can be sent.