qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v3 4/5] socket: Add num connections to qio_net_l


From: Daniel P . Berrangé
Subject: Re: [Qemu-devel] [PATCH v3 4/5] socket: Add num connections to qio_net_listener_open_sync()
Date: Wed, 4 Sep 2019 14:57:14 +0100
User-agent: Mutt/1.12.1 (2019-06-15)

On Wed, Sep 04, 2019 at 03:19:21PM +0200, Juan Quintela wrote:
> Eric Blake <address@hidden> wrote:
> > On 8/20/19 5:48 AM, Juan Quintela wrote:
> >> Reviewed-by: Daniel P. Berrangé <address@hidden>
> >> Signed-off-by: Juan Quintela <address@hidden>
> >> ---
> >>  blockdev-nbd.c            | 2 +-
> >>  chardev/char-socket.c     | 2 +-
> >>  include/io/net-listener.h | 2 ++
> >>  io/net-listener.c         | 3 ++-
> >>  migration/socket.c        | 2 +-
> >>  qemu-nbd.c                | 2 +-
> >>  ui/vnc.c                  | 4 ++--
> >>  7 files changed, 10 insertions(+), 7 deletions(-)
> >
> > Just now noticing this one, even though the pull request is already sent...
> >
> >> 
> >> diff --git a/blockdev-nbd.c b/blockdev-nbd.c
> >> index 7a71da447f..c621686131 100644
> >> --- a/blockdev-nbd.c
> >> +++ b/blockdev-nbd.c
> >> @@ -101,7 +101,7 @@ void nbd_server_start(SocketAddress *addr, const char 
> >> *tls_creds,
> >>      qio_net_listener_set_name(nbd_server->listener,
> >>                                "nbd-listener");
> >>  
> >> -    if (qio_net_listener_open_sync(nbd_server->listener, addr, errp) < 0) 
> >> {
> >> +    if (qio_net_listener_open_sync(nbd_server->listener, addr, 1, errp) < 
> >> 0) {
> >>          goto error;
> >>      }
> >
> > Does this interfere with the ability to have more than one client
> > connect to an NBD server during pull-mode incremental backup?  Or can
> > you still have multiple simultaneous clients, provided that the server
> > has finished accepting the connection from the first before the second
> > one starts?
> 
> It is exactly the same than the old code.  Old code always use one.  We
> need to have more than one for multifd.
> 
> Once told that, if the connections don't start "very" simultaneosly
> (i..e. With multifd we start <num channels> connections in paraller),
> you will never notice that the backlog is one (sie of queue of pending
> connections nowadays).

If incremental backup needs multiple concurrent connections, then
you certainly *do* want to increase this value to something other
than 1, or you will get random failures. As Juan says, this is a
pre-existing problem with NBD though.


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|



reply via email to

[Prev in Thread] Current Thread [Next in Thread]