From: Daniel Bareiro Subject: Re: VNC server for KVM VM Date: Fri, 14 Aug 2009 21:38:00 -0300 Message-ID: <20090815003800.GB32226@defiant.freesoftware.org> References: <20090814205839.GA32226@defiant.freesoftware.org> <4A85D6E0.6060103@messageone.com> Reply-To: dbareiro@gmx.net Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="tjCHc7DPkfUGtrlw" To: kvm@vger.kernel.org Return-path: Received: from mail.gmx.net ([213.165.64.20]:47216 "HELO mail.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1752863AbZHOAiE (ORCPT ); Fri, 14 Aug 2009 20:38:04 -0400 Received: from defiant (defiant.freesoftware.org [10.1.0.65]) by hermes.freesoftware.org (Postfix) with ESMTP id D5240892 for ; Fri, 14 Aug 2009 21:37:49 -0300 (ART) Content-Disposition: inline In-Reply-To: <4A85D6E0.6060103@messageone.com> Sender: kvm-owner@vger.kernel.org List-ID: --tjCHc7DPkfUGtrlw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Friday, 14 August 2009 16:28:00 -0500, Charles Duffy wrote: > >inet_listen: bind(ipv4,0.0.0.0,5903): Address already in use > >inet_listen: FAILED >=20 > If you check with netstat, I expect you'll see the port in TIME_WAIT > state; if so, this will eventually clean itself up if you just wait a > little bit before restarting. >=20 > One option to avoid it is to make sure all connections are closed > properly on shutdown; another is to set the SO_REUSEADDR flag on the > socket before the bind() call. Two were the VM to which I did shutdown and later I boot again. These VM had VNC servers running in 5902 and 5903. Approximately three hours of boot, I see the following thing with netstat: root@ss03:~# netstat -puta | grep 590 tcp 0 0 localhost:5900 *:* LISTEN = 7332/qemu-system-x8 tcp 0 0 *:5901 *:* LISTEN = 17528/qemu-system-x tcp 0 0 localhost:5902 *:* LISTEN = 30889/qemu-system-x tcp 0 0 localhost:5903 *:* LISTEN = 30900/qemu-system-x Now 5900 and 5901 are the ports that these two machines have assigned. It are up and running. Also I have other two VM without shutdown/boot it with associated VNC ports 5904 and 5905, but that don't appear in the listing of netstat, as you can see. Testing of connection I see that I cannot be connected to any of them using VNC client, although I don't remember to have observed some error when launching the KVM processes of each of them, which draws attention to me. Thanks for your reply. Regards, Daniel --=20 Fingerprint: BFB3 08D6 B4D1 31B2 72B9 29CE 6696 BF1B 14E6 1D37 Powered by Debian GNU/Linux Squeeze - Linux user #188.598 --tjCHc7DPkfUGtrlw Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkqGA2gACgkQZpa/GxTmHTe82wCgiYPBOzkiSHEONQWuC2b25Xdz 6+kAnjHCt6mbcD9DEvjmakNs3g1ROkTK =GXG1 -----END PGP SIGNATURE----- --tjCHc7DPkfUGtrlw--