I'm trying to get MAAS to talk to virsh on localhost to not have to configure a whole extra physical machine to run deployment service juju on. MAAS seems to be able to deploy a virtual machine to this extent and the host it's running on is more than capable of meeting the requirements (seems to be 4GB of RAM, which it has 20 of).
In MAAS, I go to the tab KVM, set the Name as local_kvm
, leave Zone, Resource Pool, and Password (optional) as default, and set the Address to either of
qemu+ssh://root@localhost/system
qemu:///system
In both cases: It's failing with the very unhelpful error message:
Failed talking to pod: Failed to login to virsh console.
Directly running:
virsh -c <address>
succesfully connects to the local virsh console after accepting/trusting 127.0.0.1 as a host. Of course, thinking that perhaps the MAAS gui doesn't 'force' the SSH connection through if it does not recognize/trust the host, I try again with the MAAS GUI, yet after doing so trying to do so in the GUI again fails with the same error message.
Which just states 'it failed', but doesn't really tell me why. Here's what I'd like to know:
- What user is this being executed as?
- What command is MAAS trying to execute?
- Where can I find a log file containing detailed reasons as to why the qemu/ssh connection failed?
- Is it possible that this error message is printed regardless of what went wrong, because I haven't configured storage, networks, etc. yet for KVM/libvirt-qemu, apart from removing DHCP from it.
Note that I already installed qemu on the host, running plain virsh
on the terminal as root works.
A lot of the instructions online refer to a maas user, yet I do not have this user on the machine. The thing was installed via apt as the root account, and the services appear to run as such, on root. Perhaps it shouldn't, to make things work, but then the question becomes: how do I change it not to do this, while not completely breaking it, as I'd imagine lots of necessary (virtual) files are owned by root that would need to be changed?