Bridging is broken on virt-manager

From my previous thread:
https://forums.opensuse.org/showthread.php/526524-Beginning-with-KVM?p=2834727#post2834727

So as I mentioned, a network bridge should have been created back when installing kvm through Yast, but virt-manager doesn’t recognize it!
You can see in my post what options I am given, but the real problem here is, I’m missing this option
“Bridge br0: host device eth0”
Instead given a grayed out message “no virtual networks available”!!
In command line I type “ip addr” and effectively only the 3 usual interfaces: lo, eth0 and wlan0. No br0 at all!!

W T F!? I’ve been broken ALL the freaking time!! Libvirt has BUG!

Any help please?

Hi
Not really, you need to go into YaST Network Settings and create the bridge device, then attach to the ethernet interface. Once that’s done it will be available in virt-manager.

Or create via brctl from the command line…


brctl addbr br0
brctl addif br0 eth0

@malcolmlewis:
I cannot understand it… Why does one still have to manually create the bridge? Wasn’t it supposed to be created precisely by Yast the moment KVM server was installed? I installed KVM through Yast following the opensuse guide, and after downloading and installing the packages it asked to install a bridge device, for which I answered “yes”.

(And as a very very brief offtopic, do you happen to know something about the SPICE thing? See my other thread…)

Better to create your bridge devices using vm manager.
When creating a bridge device using vm manager, your devices will be named something like “virbr0” instead of “br0”
The reason why it’s best to use libvirt (vm manager) to create these devices is that you can configure many more options within the device.

However,
No matter how you create your device (eg during virtualization install, YaST, command line, some other virtualization app, etc) the device should be available for your Guests.

TSU

So no one really can help with this issue? Am I really alone in it? Know this is extremly frustrating!

On Sun 20 Aug 2017 04:56:01 PM CDT, F style wrote:

F_style;2834878 Wrote:
> So as I mentioned, a network bridge should have been created back when
> installing kvm through Yast, but virt-manager doesn’t recognize it!
> You can see in my post what options I am given, but the real problem
> here is, I’m missing this option
> “Bridge br0: host device eth0”
> Instead given a grayed out message “no virtual networks available”!!
> In command line I type “ip addr” and effectively only the 3 usual
> interfaces: lo, eth0 and wlan0. No br0 at all!!
So no one really can help with this issue? Am I really alone in it? Know
this is extremly frustrating!

Hi
I can setup a test machine tomorrow with three ethernet ports and wifi
(for management). But I have always just installed libvirt/qemu and
created the bridges manually since I never install/run a desktop on this
type of machine… then I just connect from a remote machine with
virt-manager or ssh and virsh…

The question I guess is was the ethernet port in use when you created
stuff?

I would suspect you need to go into YaST network settings and
unconfigure the ethernet port (as in just delete it) and it will show
as unconfigured. Then In virt-manager see if you can create a virbr0
interface.

Else just create a br0 via YaST or command line.


Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
openSUSE Leap 42.2|GNOME 3.20.2|4.4.79-18.26-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below… Thanks!

@malcolmlewis:

Thanks very much sir. It would greately help me if you could do that. Though that doesn’t mean I’ll stop searching on my own neither.

In this laptop I only have 2 physical interfaces, eth0 and wifi0. When doing the create virtual machine stuff yes, eth0 is in use, while wifi0 is not. Also, I have only attempted the pure virtual machine creation “wizard”; I have never actually finished the process by hitting “create machine”, only hitting “cancel installation”.

So the reason this is getting complicated to diagnose is, I’m most likely the first dumb to attempt whole KVM and guest installations through Yast, while everyone else do at least the bridge creation manually through command line or not accepting Yast offering when installing KVM server…

I guess I could certainly manually create the bridge device, but what’s greately grinding my nerves now is the fact Yast’s automatic bridge creation during KVM server installation is seemingly not working.
Maybe the vhost-net mistake I did has to do? https://forums.opensuse.org/showthread.php/526524-Beginning-with-KVM?p=2833906#post2833906

On Sun 20 Aug 2017 06:56:02 PM CDT, F style wrote:

@malcolmlewis:

Thanks very much sir. It would greately help me if you could do that.
Though that doesn’t mean I’ll stop searching on my own neither.

In this laptop I only have 2 physical interfaces, eth0 and wifi0. When
doing the create virtual machine stuff yes, eth0 is in use, while wifi0
is not. Also, I have only attempted the pure virtual machine creation
“wizard”; I have never actually finished the process by hitting “create
machine”, only hitting “cancel installation”.

So the reason this is getting complicated to diagnose is, I’m most
likely the first dumb to attempt whole KVM and guest installations
through Yast, while everyone else do at least the bridge creation
manually through command line or not accepting Yast offering when
installing KVM server…

I guess I could certainly manually create the bridge device, but what’s
greately grinding my nerves now is the fact Yast’s automatic bridge
creation during KVM server installation is seemingly not working.
Maybe the vhost-net mistake I did has to do? http://tinyurl.com/yaqrmwyp

Hi
Ok, so you need to use wireless for the machine (host running kvm), the
enterent port must be free to use as a bridge, else if you only want to
use the ethernet port for your machine then the VM’s must use NAT.

Bridging won’t work over wireless only ethernet…


Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
openSUSE Leap 42.2|GNOME 3.20.2|4.4.79-18.26-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below… Thanks!

Wait WHAT?
I didn’t read anywhere else around internet nor I was told by anyone that in order to create a bridge for a KVM virtual guest one had to have the desired network device to share “free”! Is this the reason Yast’s bridge creation is not working?
And what does it mean? Is it enough to just unplug ethernet cable, or one must disable the device with ip command?

From what I have read around internet all day along, a bridged setting should be the more complete and flexible one for KVM guests! Once set up, it should allow everything in communication at same time: virtual guest to host, virtual guest to other physical PCs in physical LAN, virtual guest to other virtual guests either in host itself and other hosts, internet access. Which implies host’s “shared” network device should still be functional for host itself!
NAT on the other hand, from what I read, only provides internet access and to other outer networks, but no guest to host communication.

W T H?

Hi
A bridge device needs to be free, not configured, no ip address etc.

Have a read here (See Solution 1 to the right for SUSE);
https://www.linux-kvm.org/page/Networking

I see they say to use ip link now instead of brctl…

Link gives me this
“Your connection is not secure”
Using Firefox 52.0.2 on another Linux distro because I’m not at office right now.

How do I temporarily free the eth0 device? Is it enough to just unplug ethernet cable? Is this the reason Yast’s automatic bridge creation is not being recognized by virt-manager?
It’s NOT possible to install openSUSE without having the eth0 already configured! This may be a laptop, but think a common desktop PC! Normally one and only one network device, and it’s normally eth0!

Hi
Link works fine here, use Networking - KVM then…

No you need to go to YaST and delete the eth0 connection so it is states "Not Configured’ as per the link instructions…

  • Start YaST
  • Go to Network Configuration
  • Add new device -> Bridge
  • Tick your existing network device
  • done

I suggest you use your wireless connection for the host system… or if only have ethernet access look at getting a USB ethernet dongle to supplement your setup.

Cannot be!

Proxmox’s network model allows everything I need:
virtual guest to host, virtual guest to other physical PCs in physical LAN, virtual guest to other virtual guests either in host itself and other hosts, and all corresponding viceversas, aside internet acces from virtual guest of course. Which implies host’s “shared” eth0 should still be functional for host itself!
It works for Proxmox, I saw it.

And linux-kvm link says bridge mode literally takes out connection from host, leaving it with no connection while virtual guest is in use! WTH!?
So there’s definitely no way to have everything in libvirt, and Proxmox simply uses another magic?

Hi
Then install promox then?

I’m sure you can add additional bridges, vlans etc, have never worried… I’ve always used physical interfaces on the desktop machine, so I use an additional card for VM’s and bridges as I don’t want everything congested :wink: I use mainly laptops and RPi’s now… no need for VM’s…

I broke out this specific question about Virtual Networking Basics into a separate thread…

https://forums.opensuse.org/showthread.php/526669-Virtual-Networking-some-Basics-All-OS

For anything specific to that post, you can ask over there…
For anything that’s more specific to this personal situation, you can continue to post in this thread…

@malcolmlewis:

Wait… and after reading recent tsu2’s thread… are “br” and “virbr/vmbr” actually very different types of devices, with different ways of working? Could it be br is the one needing to be shut down beforehand?

Hi
Not sure… :wink:

OK, dragged a laptop out of the junk box, stuck in RAM and a HDD and installed openSUSE Leap 42.3, standard install of openSUSE GNOME and enabled ssh.

Once booted to the desktop, fired up YaST lan and set to use wicked and allocated a static ip address to the wifi and unconfigured eth0, that’s all no bridge etc.

Then added a LVM group and a 100GB volume for /var/lib/libvirt.

Then into YaST and select the hypervisior option and a KVM Server;

http://thumbs.imagebam.com/69/e4/f8/db8d4b582349773.jpg](http://www.imagebam.com/image/db8d4b582349773)

http://thumbs.imagebam.com/7b/e4/a6/ae4cae582349783.jpg](http://www.imagebam.com/image/ae4cae582349783)

It setup the bridge device without a problem to eth0…

Connect from my local machine to bert over ssh to the libvirt running instance, in the dropdown is br0…

http://thumbs.imagebam.com/9c/4a/57/b59ef1582349803.jpg](http://www.imagebam.com/image/b59ef1582349803)

Now if I look in YaST Network Settings it has added a Network Bridge br0, so I can’t see it being broken…

I would surmise your using NetworkManager and not Wicked?

Just read your other reply as well.

First of all, what’s “bert”?

Second, I think Yast did create a br0 device in my case, but I also notice that you seem to be creating a virtual network device from virt-manager instead of virt-installer.
Mr tsu2 also suggested so in his thread. But, what options are you shown if trying to set up network directly from virt-installer’s step 5, while indeed creating a new vm?
Though unfortunately I heavily suspect you’ll be given the br option because you turned eth0 off…

Hi
That’s the hostname (bert) of the system… I use muppet names :wink: So I can have virtual machines running on any system and then use virt-manager over ssh from just one system to talk/manage them…

You setup via the Manager depending on what your wanting to do, what network range etc… If it’s setup before you create the machine you can add during install, else setup something later and just edit the machine details…

On Mon 21 Aug 2017 05:06:02 AM CDT, malcolmlewis wrote:

F_style;2835026 Wrote:
> Just read ‘your other reply’ (http://tinyurl.com/yao9skpr) as well.
>
> First of all, what’s “bert”?
>
> Second, I think Yast did create a br0 device in my case, but I also
> notice that you seem to be creating a virtual network device from
> virt-manager instead of virt-installer.
> Mr tsu2 also suggested so in his thread. But, what options are you
> shown if trying to set up network directly from virt-installer’s step
> 5, while indeed creating a new vm?
> Though unfortunately I heavily suspect you’ll be given the br option
> because you turned eth0 off…
Hi
That’s the hostname (bert) of the system… I use muppet names :wink: So I
can have virtual machines running on any system and then use
virt-manager over ssh from just one system to talk/manage them…

You setup via the Manager depending on what your wanting to do, what
network range etc… If it’s setup before you create the machine you can
add during install, else setup something later and just edit the machine
details…

Hi
Oops, whilst br0 was added still need to create the link to eth0…


brctl show
bridge name	bridge id		STP enabled	interfaces
br0		8000.7446a0740c80	no		eth0
vnet0
virbr0		8000.525400e6d3a4	yes		virbr0-nic


Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
openSUSE Leap 42.2|GNOME 3.20.2|4.4.79-18.26-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below… Thanks!