Create and Configure Bridge Networking For KVM in Linux

KVM (Kernel-based Virtual Machine) is an open-source hypervisor for Linux that allows multiple virtual machines to run on a single physical machine. One of the key features of KVM is its ability to provide network connectivity to virtual machines using different networking models, including bridge networking.
This article will discuss further how to perform KVM bridge network setup for KVM on Linux. We will start by briefly explaining the concept of bridge networking and its benefits, and then we will walk through the steps required to configure bridge networking for KVM in Linux.
Before You Start
These are the prerequisites. This guide assumes:
-
KVM is installed and working (libvirt, qemu-kvm)
-
You are using a Linux host (Ubuntu, Debian, RHEL, Rocky, Alma, Fedora)
-
Your system uses NetworkManager or netplan
-
You have root or sudo access
-
You know the name of your physical interface (eth0, ens3, enp0s3, etc.)
What is a Virtual Network Bridge?
Bridge networking is a method of connecting virtual machines to the external network by creating a virtual bridge between the physical network interface card (NIC) and the virtual network interface card (VNIC) of the virtual machine.
The virtual bridge acts as a software switch that connects multiple VNICs to the host’s physical NIC. This allows virtual machines to appear as full network peers, receiving IP addresses from the same network as the host.
This is the most common and practical model for KVM networking when VMs need real LAN or internet access.
Why Would You Need to Configure Bridge Networking for KVM in Linux?
You typically use KVM network bridge configuration for:
Improved Network Performance
Bridge networking allows VMs to be directly accessible on the LAN and avoids NAT translation, which can simplify networking and reduce some overhead.
Simplified Network Configuration
Bridge networking eliminates the need for complex network configurations and allows virtual machines to obtain IP addresses from the same DHCP server as the host machine.
Flexible Network Topology
Bridge networking provides a flexible network topology that allows virtual machines to communicate with each other and the external network without restrictions.
How Do I Create a Virtual Machine Manager Bridge Network?
GUI-based setup works but has limitations. It is useful for testing, not ideal for production. Here’s a step-by-step guide on how to create a bridge in Virtual Machine Manager:
Step 1: Create a Virtual Network
In Virtual Machine Manager (VMM):
Edit → Connection Details → Virtual Networks → New
Choose Forwarding Mode: Bridge and select your physical interface.
Step 2: Attach VMs
For each VM:
Settings → Network → Source → Select the bridge
Step 3: Validate
The VM should receive an IP from your LAN DHCP server.
Limitation: VMM does not persist cleanly across reboots on all distros and may conflict with NetworkManager.
CLI-Based KVM Bridge Network Setup (Recommended)
On modern systems using NetworkManager:
nmcli connection add type bridge ifname br0 con-name br0
nmcli connection add type ethernet ifname ens3 master br0
nmcli connection up br0
Replace ens3 with your real interface.
VMs should use br0 as their network source.
KVM Bridge vs Passthrough
A KVM bridge network is a software-based solution that creates a virtual switch. This virtual switch connects virtual machines to the physical network using the host’s network interface card (NIC), allowing VMs to communicate with each other and external systems through the host.
KVM network passthrough, on the other hand, uses IOMMU technologies such as Intel VT-d or AMD-Vi to map a physical NIC directly to a virtual machine. This allows the VM to bypass the host networking stack, reducing overhead and enabling near-native network performance. While passthrough relies on hardware virtualization support, it is implemented and managed through the hypervisor rather than being a purely hardware-based approach.
When to Use a KVM Bridge Network
A bridge network is the best choice in most environments because:
-
It is easy to configure and manage
-
It does not require special hardware
-
Multiple VMs can share a single NIC
-
It provides good performance for typical server workloads
However, because traffic passes through a virtual switch, very high-bandwidth or latency-sensitive workloads may see some performance impact.
When to Use Passthrough
Passthrough is better suited for specific scenarios where maximum performance is required:
-
High-throughput or low-latency workloads
-
Network appliances or specialized infrastructure
-
Situations where near-native NIC performance is critical
The trade-off is that passthrough requires compatible hardware (such as Intel VT-d or AMD-Vi), a more complex configuration, and dedicates the physical NIC to a single VM.
So:
-
Use bridge networking for most virtualization deployments and general-purpose servers.
-
Use passthrough when performance requirements outweigh flexibility, and hardware constraints are not an issue.
Common Failure Scenarios (Troubleshooting)
No Internet After Setup
-
The physical interface still has IP assigned (should move to bridge)
-
Bridge not set as default route
VM Has No IP Address
-
DHCP server blocked
-
Wrong interface attached
-
Firewall blocking bridge traffic
NetworkManager / Netplan Conflict
-
Two tools managing same interface
-
Disable one to avoid race conditions
Host Loses Connectivity
-
Physical NIC misbound
-
Bridge created without enslaving the interface
What is the Difference Between a Switch and a Bridge?
Both switches and bridges operate at the data link layer and use MAC addresses to forward traffic between devices. In practice, a network bridge performs basic traffic forwarding between segments, while a switch is a more advanced device that can handle multiple ports efficiently and provide features such as VLANs and traffic management. In modern environments, Linux bridges used in KVM act as software switches rather than traditional standalone bridge devices.
In conclusion, knowing how to configure a KVM bridge network in Linux is very important for your business. Contact our 24/7 support team now at HostSailor to get personalized assistance.
FAQs
1. What is KVM in networking?
KVM provides virtual network interfaces for VMs using bridge, NAT, or passthrough models.
2. How to bridge a virtual machine network?
Create a bridge on the host, attach the physical NIC, then connect VM interfaces to that bridge.
3. Is KVM bridge better than NAT?
It depends on the use case. A bridge network is often preferred when virtual machines need direct network access or inbound connectivity. NAT is simpler to configure and works well for isolated environments or cases where outbound access is sufficient.