#641083 virt-manager: Unable to establish qemu+ssh connection due to no prompt for password

#641083#5
Date:
2011-09-10 08:41:10 UTC
From:
To:
(This is similar to bug 614291 but the cause is different.)

I have successfully used virt-manager to connect to a libvirt managed
KVM server via SSH in the past.

I'm not sure what caused the failure, but for the previously working
qemu+ssh://jonathan@patonga/system connection I now get the following
error message.
------------------------------------------------------------------------
Unable to open a connection to the libvirt management daemon.

Libvirt URI is: qemu+ssh://jonathan@patonga/system

Verify that:
 - The 'libvirtd' daemon has been started


 Cannot recv data: No protocol specified

 (ssh-askpass:9481): Gtk-WARNING **: cannot open display: :0.0
 Permission denied, please try again.

 No protocol specified

 (ssh-askpass:9482): Gtk-WARNING **: cannot open display: :0.0
 Permission denied, please try again.

 No protocol specified

 (ssh-askpass:9483): Gtk-WARNING **: cannot open display: :0.0
 Permission denied (publickey,password).
 : Connection reset by peer

 Traceback (most recent call last):
   File "/usr/share/virt-manager/virtManager/connection.py", line 1146,
   in _open_thread
       self.vmm = self._try_open()
	     File "/usr/share/virt-manager/virtManager/connection.py", line
		 1130, in _try_open
		     flags)
			   File "/usr/lib/python2.6/dist-packages/libvirt.py", line
			   102, in openAuth
			       if ret is None:raise
				   libvirtError('virConnectOpenAuth() failed')
				   libvirtError: Cannot recv data: No protocol specified

				   (ssh-askpass:9481): Gtk-WARNING **: cannot open
				   display: :0.0
				   Permission denied, please try again.

				   No protocol specified

				   (ssh-askpass:9482): Gtk-WARNING **: cannot open
				   display: :0.0
				   Permission denied, please try again.

				   No protocol specified

				   (ssh-askpass:9483): Gtk-WARNING **: cannot open
				   display: :0.0
				   Permission denied (publickey,password).
				   : Connection reset by peer
------------------------------------------------------------------------ ssh-askpass doesn't give me a dialog to enter a password. That, I think, is the problem. And, if I start the remote virtual machine via virsh then I can use virt-viewer to connect to the virtual machine's graphical console.
#641083#10
Date:
2011-12-09 03:11:35 UTC
From:
To:
HI,
I was having the same problem in Oneiric 64 bit. I was using the
cmd line to launch virt-manager using  $ virt-manager.  The issue was
solved when:
a. I had installed ssh-askpass into my system
b. I started using GUI and not cmd line to launch virt-manager. When
cmdlink is used we get some GTK warnings which may also be the cause of
the issue.

Regs,
Deepak