You are not logged in.

#1 2024-06-08 17:40:36

archuser38013
Member
Registered: 2024-01-27
Posts: 96

[SOLVED] No network connections on libvirt vms after system update

Default nat.

I was scratching my head thinking it was one of the vms at issue then I thought to check a different, unrelated one and that was down too.

I had done a full system update earlier in the day so must have borked it somehow.

Just using the default nat of libvirt.

How should I proceed to diagnose/fix the issue?

Routing stuff I am pretty clueless with. I began reading Network Warrior to try and help me out with that but not got far yet!

Last edited by archuser38013 (2024-06-17 11:15:52)

Offline

#2 2024-06-08 22:19:49

groll-ay
Member
Registered: 2023-02-10
Posts: 6

Re: [SOLVED] No network connections on libvirt vms after system update

Using UFW firewall? See here:

https://www.reddit.com/r/archlinux/comm … etworking/
and
https://gitlab.com/libvirt/libvirt/-/issues/644

In my case none of the proposed solutions worked, I had to rollback (with timeshift), perhaps I misconfigured something while trying to find a solution.

Offline

#3 2024-06-09 08:23:58

archuser38013
Member
Registered: 2024-01-27
Posts: 96

Re: [SOLVED] No network connections on libvirt vms after system update

groll-ay wrote:

Using UFW firewall? See here:

https://www.reddit.com/r/archlinux/comm … etworking/
and
https://gitlab.com/libvirt/libvirt/-/issues/644

In my case none of the proposed solutions worked, I had to rollback (with timeshift), perhaps I misconfigured something while trying to find a solution.

Thanks. Yes I am also using ufw.

I thought, being a fairly recent install on this machine, I would first try out nftables however this has brought me a host of new issues sad as when I enabled it it deleted my previous routes and has somehow broken Network Manager. Have made a new post about that.

System updates ... usually 1 step forward 2 steps back big_smile.

EDIT: Hi, just for your information, or anyone else it might help. The replies about editing the default firewall backend in

/etc/libvirt/network.conf

from the reddit thread you posted worked for me.

So not sure why it didn't work for you but just a heads up that it worked for me and thanks for the link!

Last edited by archuser38013 (2024-06-09 14:46:30)

Offline

#4 2024-06-10 00:19:01

groll-ay
Member
Registered: 2023-02-10
Posts: 6

Re: [SOLVED] No network connections on libvirt vms after system update

EDIT: Hi, just for your information, or anyone else it might help. The replies about editing the default firewall backend in

/etc/libvirt/network.conf

from the reddit thread you posted worked for me.

So not sure why it didn't work for you but just a heads up that it worked for me and thanks for the link!

I'll try this again, when I have more time. At the moment I've simply blocked libvirt to the previous version. Thanks!

Offline

#5 2024-06-10 06:41:12

glenjo
Member
From: Pacific NW
Registered: 2020-06-09
Posts: 43

Re: [SOLVED] No network connections on libvirt vms after system update

Editing /etc/libvirt/network.conf to use iptables worked for me!

Thanks!

Offline

#6 2024-06-11 00:11:47

groll-ay
Member
Registered: 2023-02-10
Posts: 6

Re: [SOLVED] No network connections on libvirt vms after system update

So, finally I can confirm, that editing /etc/libvirt/network.conf worked for me too. Thanks!

Offline

#7 2024-06-17 11:15:17

archuser38013
Member
Registered: 2024-01-27
Posts: 96

Re: [SOLVED] No network connections on libvirt vms after system update

groll-ay wrote:

So, finally I can confirm, that editing /etc/libvirt/network.conf worked for me too. Thanks!

glenjo wrote:

Editing /etc/libvirt/network.conf to use iptables worked for me!

Thanks!

Glad y'all found it of help.

Offline

#8 2024-06-21 19:23:53

dualfade
Member
Registered: 2024-06-21
Posts: 2

Re: [SOLVED] No network connections on libvirt vms after system update

Confirmed working here as well ! Thanks for this thread.

glenjo wrote:

Editing /etc/libvirt/network.conf to use iptables worked for me!

Thanks!

Offline

#9 2024-06-25 02:38:24

archuser38013
Member
Registered: 2024-01-27
Posts: 96

Re: [SOLVED] No network connections on libvirt vms after system update

dualfade wrote:

Confirmed working here as well ! Thanks for this thread.

glenjo wrote:

Editing /etc/libvirt/network.conf to use iptables worked for me!

Thanks!

Great. I noticed this is also in the libvirt archwiki.

For network connectivity, install:

    iptables-nft and dnsmasq for the default NAT/DHCP networking. Then set firewall_backend="iptables" option in /etc/libvirt/network.conf.

I did not look at the time of the issue and just happened across it on some related search a few days ago.

Offline

#10 2024-07-20 09:59:14

archuser38013
Member
Registered: 2024-01-27
Posts: 96

Re: [SOLVED] No network connections on libvirt vms after system update

Just a heads up to those it may concern that updating the system seems to delete the file so you have to redo or make it not overwrite it when updating.

Offline

#11 2024-07-20 17:37:27

groll-ay
Member
Registered: 2023-02-10
Posts: 6

Re: [SOLVED] No network connections on libvirt vms after system update

Same here. How to "make it not overwrite it when updating"?

Offline

#12 2024-07-21 08:19:13

archuser38013
Member
Registered: 2024-01-27
Posts: 96

Re: [SOLVED] No network connections on libvirt vms after system update

groll-ay wrote:

Same here. How to "make it not overwrite it when updating"?

You can use 'sudo chattr + i /etc/libvirt/network.conf' to make it immutable. I can't attest if that will not break something down the line though if an update required some change in that file not present in the old one. Probably not I guess since things were all commented out from what I remember but just something to be aware of.

Offline

#13 2024-07-21 10:56:11

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,995

Re: [SOLVED] No network connections on libvirt vms after system update

Or you re-check the wiki and notice

https://wiki.archlinux.org/title/Libvirt#Networking wrote:

If the default network cannot be started, make sure iptables-nft and dnsmasq are installed.

By switching to iptables-nft you should not need to force libvirt to use the deprecated iptables anymore .


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#14 2024-07-23 00:21:01

groll-ay
Member
Registered: 2023-02-10
Posts: 6

Re: [SOLVED] No network connections on libvirt vms after system update

Thanks archuser38013 and Lone_Wolf. I'll leave it that way, with manual intervention when needed. chattr is not an option for me, iptables-nft and dnsmasq are installed, there must be an issue with my "special" libvirt network config, which I migrated from an older Debian, together with a couple of VMs (I still need them for the moment), that refuses to accept the new default nftables setting. At some point a new clean setup ...

Thanks smile

Offline

#15 2024-07-24 17:16:30

tekstryder
Member
Registered: 2013-02-14
Posts: 177

Re: [SOLVED] No network connections on libvirt vms after system update

See:

https://gitlab.archlinux.org/archlinux/ … -/issues/3

-and-

https://gitlab.archlinux.org/archlinux/ … fb1f79c0b3

/etc/libvirt/network.conf is now preserved during package upgrades.

Last edited by tekstryder (2024-07-24 17:18:22)

Offline

#16 2024-07-24 22:48:07

groll-ay
Member
Registered: 2023-02-10
Posts: 6

Re: [SOLVED] No network connections on libvirt vms after system update

tekstryder wrote:

[...]
/etc/libvirt/network.conf is now preserved during package upgrades.

Thats what I was hoping for wink Works - thanks! smile

Offline

Board footer

Powered by FluxBB