Greetings,
I think my question is: now that I have a new laptop and a slightly
different networking setup, how do I get QEMU to work with
systemd-resolved, but if I had all the answers, then I wouldn't be
asking for help. :-)
My symtoms are that QEMU guests (various live Linux CDs) can ping IP
addresses, but not resolve names:
$ ping -c1 archlinux.org
ping: archlinux.org: Name or service not known
$ resolvectl query archlinux.org
archlinux.org: resolve call failed: Lookup failed due to system error: Network is unreachable
$ ping -c1 95.217.163.246
PING 95.217.163.246 (95.217.163.246) 56(84) bytes of data.
64 bytes from 95.217.163.246: icmp_seq=1 ttl=255 time=414 ms
[statistics elided to conserve bandwidth]
On my old laptop, I used NetworkManager resolvconf, but on the new one,
I'm using iwctl/iwd and systemd-resolved, so I'm assuming that that's
the culprit.
In any case, I'm using the following command to start QEMU (various live
CDs boot and run with various options, but they all exhibit the same
networking symptoms; vm.qcow2 is newly created):
qemu-system-x86_64 -m 8G -enable-kvm -drive file=vm.qcow2 -cdrom /path/to/iso-image
I have no access to a wired network. I do have access to two WiFi
networks. One is from my cell phone provider. The other goes through a
captive portal over which I have no control. I get the same symptoms in
my guests either way. When using the network connection from my cell
phone provider (some output removed to remove obviously irrelevant data
and/or formatting meant for humans):
$ ping -c1 archlinux.org
PING archlinux.org (95.217.163.246) 56(84) bytes of data.
64 bytes from archlinux.org (95.217.163.246): icmp_seq=1 ttl=41 time=210 ms
$ pacman -Q qemu
qemu-desktop 7.0.0-1
$ ip a
4: wlan0: