Virtual Machine Manager | Bridged Network | Why so complicated to achiev?

(I use the Mate-Compiz spin on my desktop computer [IntensePC])

How I was able to achieve it:

  1. Connection Details, Virtual Networks, clicking on the "+" change mode to "Open" (the rest is all default). This creates me a "virbr0"
  2. Now I stop "virbr0" on the red minus icon and while clicking o the trash it disappears in the connection details. While changing to terminal and type nmcli c it is still active. I stop it with nmcli c down virbr0
  3. Back in the “Connection Details” i do create "+"a new virtual network using the default as name: network
    This time I choose Mode: NAT and do let everything as it was (default). This creates me a Network connected to virbr0
  4. Opening my VM (QEMU/KVM) under NIC I select the Network source: Virtual network 'network :NAT'
  5. Now i can start the WM and do get DHCP working. I am able to ping my host and also able to communicate between them.

I used Virtualbox before and had the option there to create a bridged connection on the vm guest choosing the Host’s NW-adapter I wanted to use as bridge.

Is there a simpler way to achieve this? And is there a tool where i can control the status of the connections? A script I can use in terminal would be ok.

1 Like

If you want to bridge the physical network to the VM, you first have to create the bridge in NetworkManager and add the physical NIC as a port of the bridge.

In this example, I’m bridging eth0 to a new bridge br0:

# nmcli con add con-name br0 ifname br0 type bridge autoconnect yes ipv4.method auto ipv6.method auto
# nmcli con add con-name br0-port ifname eth0 type ethernet slave-type bridge master br0 autoconnect yes

Note that your existing connection for the ethernet interface will have to be removed:

# nmcli con    # (Get the connection name)
# nmcli con delete "Wired connection 1"

With that in place, you can choose br0 as the bridge for your VMs.


Thanks that worked. What I observed is that the connection is much slower this way.

It also created me an Auto Ethernet connection. Is this normal ?

I’m not sure about that. I’d disable the autoconnect option of that new connection just to make sure it doesn’t get in the way:

# nmcli con modify "Auto Ethernet" connection.autoconnect no
1 Like