-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to connect to libvirt server using password, requires ssh key #17
Comments
My config: yum install -y virt-who
cr_password=`virt-who-password --password <hidden> 2> /dev/null`
user_password=`virt-who-password --password "uHCscz2QtEHY5VhH" 2> /dev/null`
cat > /etc/virt-who.d/virt-who-config-2.conf << EOF
[virt-who-config-2]
type=libvirt
hypervisor_id=hostname
owner=Default Organization
env=Library
server=<hidden>
username=root
encrypted_password=$cr_password
rhsm_hostname=https://<hidden>
rhsm_username=virt_who_reporter_2
rhsm_encrypted_password=$user_password
rhsm_prefix=/rhsm
EOF
cat > /etc/cron.d/virt-who-config-virt-who-config-2 << EOF
0 * * * * virt-who --one-shot --debug --config=/etc/virt-who.d/virt-who-config-2.conf
EOF |
I found the problem, the libvirt backend doesnt support password as per https://bugzilla.redhat.com/show_bug.cgi?id=1258726 # virt-who --one-shot --config=/etc/virt-who.d/virt-who-config-3.conf
2017-02-20 14:08:46,898 WARNING: Password authentication doesn't work with ssh transport on libvirt backend, copy your public ssh key to the remote machine
2017-02-20 14:08:46,899 WARNING: Password authentication doesn't work with ssh transport on libvirt backend, copy your public ssh key to the remote machine After configuring the ssh key for the user as mentioned in the warning above, the permission error is gone and it starts working. |
I think this is depending on how you specify the libvirt server. For local libvirt, qemu:///system without any username and password should work. For classic username and password configuration of libvirt, please see https://libvirt.org/auth.html#ACL_server_username Maybe we should provide inline help for libvirt fields with some examples. Please let me know if this helps. |
The text was updated successfully, but these errors were encountered: