No Internet from libvirt VMs after upgrading to 15.6 (with a solution)

After having upgraded my Lenovo T14 laptop to 15.6 this weekend none of the Libvirt VMs had Internet access. Just in case it would help others, here is a short description of the problem with the solution:

Sympthoms:

  1. none of the existing Libvirt VMs had internet access, yet ping 8.8.8.8 on the VMs worked fine.
  2. the host itself did have Internet access

Root cause: The upgrade process moved the existing NetworkManager config file to /etc/NetworkManager/NetworkManager.conf.rpmsave, dropped a default config in /etc/NetworkManager/NetworkManager.conf.rpmnew and left NetworkManager without a new /etc/NetworkManager/NetworkManager.conf. This is standard RPM feature when the pkg wants to upgrade a config file, but in this case left me with the default NetworkManager config (i.e.: no local dnsmasq instance, which in turn was needed by the dnsmasq instance of the default libvirt bridge)

Solution: cp /etc/NetworkManager/NetworkManager.conf.rpmsave /etc/NetworkManager/NetworkManager.conf && systemctl restart NetworkManager

HTH.

Which is the exact reason why you should never modify this file and use drop-ins in /etc/NetworkManager/conf.d.

1 Like

Which is a contradictory text.

@hcvv: so if we’re splitting hairs: NetworkManager icon in VM said “No Internet access” (or something similar). Is it wrong to try to make it recognizable for people? While technically you may be right, these kind of remarks do not invite further contribution…

good point.

I have seen here many cases of people looking at their NICs, it’s configuration, their routers, etc. while in fact they “only” had problems in resolving hostnames.

Trying to learn what are the correct terms to explain a problem to others instead of saying “the internet is down” (I really saw that), isn’t a bad thing in my opinion.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.