WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Re: [Qemu-devel] vnc port selection

To: Anthony Liguori <anthony@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] Re: [Qemu-devel] vnc port selection
From: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Date: Tue, 26 Aug 2008 11:15:41 +0100
Cc: Xen Development Mailing List <xen-devel@xxxxxxxxxxxxxxxxxxx>, qemu-devel@xxxxxxxxxx
Delivery-date: Tue, 26 Aug 2008 03:16:06 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <48ADB58D.9070409@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Newsgroups: chiark.mail.xen.devel
References: <48AD99CF.6070004@xxxxxxxxxx> <48ADB43D.9050401@xxxxxxxxxxxx> <48ADB58D.9070409@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Anthony Liguori writes ("[Xen-devel] Re: [Qemu-devel] vnc port selection"):
> Avi Kivity wrote:
> > Presumably -vncunused is passed by the management application, which 
> > knows about all domains.  Can't it figure out an unused port and pass 
> > it on?
> 
> An argument for this sort of semantics is that if you just launch 
> vncserver with no argument, it'll sit on the first unused port.  So 
> people are sort of used to this behavior.

Exactly.  So that's why we need both the ability to do this, and the
ability to find out what port was eventually used.

> > Alternatively, have the management application pass an fd denoting the 
> > socket.
> 
> If you are allocating the ports in the management tool, then just tell 
> QEMU what port to open up.  I don't think you gain anything passing an fd.

That has a race, because you commit to the port before having
prevented another application from grabbing it.  I think the `pick
unused port' option is more sensible.

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel