[et-mgmt-tools] Re: [PATCH] use localhost when connecting local VNC guest console
Daniel P. Berrange
berrange at redhat.com
Fri Aug 31 17:54:20 UTC 2007
On Fri, Aug 31, 2007 at 07:05:43PM +0200, Bernhard Kaindl wrote:
> On Fri, 31 Aug 2007, Bernhard Kaindl wrote:
>
> >and if that is so (both are the hostname of the local machine) then
> >the VNC connection can be directed to 127.0.0.1 as before:
> >
> >--- virt-manager--devel/src/virtManager/domain.py
> >+++ virt-manager--devel/src/virtManager/domain.py
> >@@ -456,7 +456,12 @@ def get_graphics_console(self):
> >
> > transport, username = self.connection.get_transport()
> >
> >- return [type, self.connection.get_hostname(), port, transport]
> >+ hostname = self.connection.get_hostname()
> >+
> >+ if hostname == self.connection.get_local_hostname():
> >+ hostname = "127.0.0.1"
> >+
> >+ return [type, hostname, port, transport]
> >
> >
> > def get_disk_devices(self):
>
> Note: The message which was displayed when the gtk-vnc widget got the
> ECONNREFUSED (Connection refused) error when connecting to <hostname>:5900
> sounds a bit misleading to me.
>
> socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 4
> connect(4, {sa_family=AF_INET, sin_port=htons(5900),
> sin_addr=inet_addr("<my host's LAN IP address here>")}, 16) = -1
> ECONNREFUSED (Connection refused)
>
> The message resulting from this was:
>
> "Console was disconnected from guest"
Yes, I still need to get proper error reports being propagated out from
GTK-VNC back to the app. It'll addressed in next GTK-VNC i hope.
Dan.
--
|=- Red Hat, Engineering, Emerging Technologies, Boston. +1 978 392 2496 -=|
|=- Perl modules: http://search.cpan.org/~danberr/ -=|
|=- Projects: http://freshmeat.net/~danielpb/ -=|
|=- GnuPG: 7D3B9505 F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 -=|
More information about the et-mgmt-tools
mailing list