Hi,
I am using python libvirt api to get domain information. When using a uri without specifying the socket path, an error occurs.
uri = "qemu+ssh://myuser@xxxxxxxxxxxxx/system"
conn = libvirt.open(uri)
This results in the following:
libvirt: XML-RPC error : internal error: received hangup event on socket
If I append the socket path to the URI, it works. e.g.
qemu+ssh://myuser@xxxxxxxxxxxxx/system?socket=/var/run/libvirt/libvirt-sock
Is this the recommended way to construct an ssh uri? My concern is that the socket path may be different when connecting to different libvirt hosts.
remote host is ubuntu 20.04 running libvirtd (libvirt) 6.0.0 under systemd
- Joe