From: Peter Krempa <pkrempa@redhat.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: Xiong Zhou <xzhou@redhat.com>,
libvir-list@redhat.com, qemu-devel@nongnu.org,
kvm@vger.kernel.org
Subject: Re: [Qemu-devel] [libvirt] Fail to start 2nd guest
Date: Mon, 27 Feb 2017 14:38:05 +0100 [thread overview]
Message-ID: <20170227133805.GG3900@andariel.pipo.sk> (raw)
In-Reply-To: <20170227133130.GS28403@stefanha-x1.localdomain>
[-- Attachment #1: Type: text/plain, Size: 2010 bytes --]
On Mon, Feb 27, 2017 at 13:31:30 +0000, Stefan Hajnoczi wrote:
> On Mon, Feb 27, 2017 at 08:50:03PM +0800, Xiong Zhou wrote:
> > On Mon, Feb 27, 2017 at 10:11:04AM +0000, Stefan Hajnoczi wrote:
> > > On Mon, Feb 27, 2017 at 05:40:50PM +0800, Xiong Zhou wrote:
[...]
> > > > sh-4.2# virsh start 73us
> > > > error: Failed to start domain 73us
> > > > error: internal error: qemu unexpectedly closed the monitor: ((null):11497): Spice-Warning **: reds.c:2499:reds_init_socket: listen: Address already in use
> > > > 2017-02-27T09:33:42.335708Z qemu-kvm: failed to initialize spice server
> > >
> > > The error message says that the spice remote desktop cannot listen on
> > > -spice port=5900,addr=127.0.0.1.
> > >
> > > Did you hardcode port 5900 in the domain XML? That could explain why
> > No.
> > > the second guest fails to launch - you need to use unique port numbers
> > > or let libvirt automatically assign them. Check the domain XML:
> > >
> > > <graphics type='spice' port='-1' tlsPort='-1' autoport='yes'>
> >
> > It looks like:
> >
> > <graphics type='spice' autoport='yes'>
> > <listen type='address'/>
> > <image compression='off'/>
> > </graphics>
> >
> >
> > >
> > > Another possibility is that a process running on the host is already
> > > using port 5900. Perhaps a guest or VNC server that was launched
> > > outside of libvirt? You can check this with:
> > >
> > > netstat -alpn | grep 5900
> > # netstat -alpn | grep 5900
> > tcp 0 0 127.0.0.1:5900 0.0.0.0:* LISTEN 11065/qemu-kvm
>
> Please check that 11065/qemu-kvm was launched by the same libvirtd and
> its domain XML also uses autoport='yes'.
>
> I have CCed the libvirt mailing list because they may be able to explain
> why there is a collision on TCP port 5900.
There was a bug in the code. There could be a race between startup of
two VMs:
https://bugzilla.redhat.com/show_bug.cgi?id=1397440
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
prev parent reply other threads:[~2017-02-27 13:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-27 9:40 [Qemu-devel] Fail to start 2nd guest Xiong Zhou
2017-02-27 10:11 ` Stefan Hajnoczi
2017-02-27 12:50 ` Xiong Zhou
2017-02-27 13:31 ` Stefan Hajnoczi
2017-02-27 13:38 ` Peter Krempa [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170227133805.GG3900@andariel.pipo.sk \
--to=pkrempa@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=libvir-list@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
--cc=xzhou@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).