Score:0

How to properly set up a KVM bridge?

mp flag

I had a big problem, no matter how I set up the bridge for KVM, the network constantly drops until I return everything as it was. I don't know what I'm doing wrong, so I'm turning to you. I tried setting up a netplan using similar guides: https://linuxhint.com/install-kvm-ubuntu-22-04/

Here is my yaml:

# Let NetworkManager manage all devices on this system
network:
  version: 2
  renderer: networkd
  ethernets:
    eno1:
      dhcp4: false
      dhcp6: false
      addresses: [192.168.1.2/24]
      nameservers:
        addresses: [1.1.1.1,1.0.0.1]
      routes:
        - to: default
          via: 192.168.1.1
          on-link: true
    enp12s0:
      dhcp4: false
      dhcp6: false
      addresses: [192.168.1.3/24]
      nameservers:
        addresses: [1.1.1.1,1.0.0.1]

Here is what I tried last time:

# Let NetworkManager manage all devices on this system
network:
  version: 2
  renderer: networkd
  ethernets:
    eno1:
      dhcp4: false
      dhcp6: false
    enp12s0:
      dhcp4: false
      dhcp6: false
      addresses: [192.168.1.3/24]
      nameservers:
        addresses: [1.1.1.1,1.0.0.1]
  bridges:
    br0:
      dhcp4: false
      dhcp6: false
      interfaces: [eno0]
      addresses: [192.168.1.2/24]
      nameservers:
        addresses: [1.1.1.1,1.0.0.1]
      routes:
        - to: default
          via: 192.168.1.1
          on-link: true

I do not know what other information to provide, but I am ready to give any

Marco avatar
br flag
The comment on the head of your yaml file says "NetworkManager", but the "renderer" is "networkd". This does not fit together.
Yan Belogorodov avatar
mp flag
I updated this server so it used network manager, but I switched to netplan. Just forgot to remove this comment in yaml
Marco avatar
br flag
Netplan only tells the real "renderer" what to do. in your case it tells "networkd" what to do.
Yan Belogorodov avatar
mp flag
I don't understand what I need to fix. Well, I understood for sure that this is the renderer line, but what should I enter there then?
Marco avatar
br flag
If your renderer is "NetworkManager", then set it in the "renderer" line ... or directly configure it in NetworkManager config. Again: netplan is only giving a hint to the real network renderer. If the real network renderer has a config, netplan config is ignored.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.