qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Wouter Verhelst <w@uter.be>
To: Eric Blake <eblake@redhat.com>
Cc: Bob Chen <a175818323@gmail.com>, nbd list <nbd@other.debian.org>,
	Stefan Hajnoczi <stefanha@gmail.com>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	qemu block <qemu-block@nongnu.org>
Subject: Re: [Qemu-devel] [Nbd] [Qemu-block] How to online resize qemu disk with nbd protocol?
Date: Tue, 14 Nov 2017 18:37:45 +0100	[thread overview]
Message-ID: <20171114173745.egvtklxyrcprlcdn@grep.be> (raw)
In-Reply-To: <09ef1805-8361-5dff-300e-deede4863e55@redhat.com>

On Tue, Nov 14, 2017 at 10:41:39AM -0600, Eric Blake wrote:
> Another thought - with structured replies, we finally have a way to let
> the client ask for the server to send resize information whenever the
> server wants, rather than having to be polled by a new client request
> all the time.  This is possible by having the server reply with a chunk
> without the NBD_REPLY_FLAG_DONE bit, for as many times as it wants,
> (that is, the server never officially ends the response to the single
> client request for on-going status, until the client sends an
> NBD_CMD_DISC).

Hrm, yeah, that could work.

Minor downside of this would be that a client would now be expected to
continue listening "forever" (probably needs to do a blocking read() or
a select() on the socket), whereas with the current situation a client
could get away with only reading for as long as it expects data.

I don't think that should be a blocker, but it might be something we
might want to document.

> I don't think the server should go into this mode without a flag bit
> from the client requesting it (as it potentially ties up a thread that
> could otherwise be used for parallel processing of other requests),

Yeah. I think we should probably initiate this with a BLOCK_STATUS
message that has a flag with which we mean "don't stop sending data on
the given region for contexts that support it".

However, I could imagine that there might be some cases wherein a server
might be able to go into such a mode for two or more metadata contexts,
and where a client might want to go into that mode for one of them but
not all of them, while still wanting some information from them.

This could be covered with metadata context syntax, but it's annoying
and shouldn't be necessary.

I'm starting to think I made a mistake when I said NBD_CMD_BLOCK_STATUS
can't take a metadata context ID. Okay, there's no space for it, but
that shouldn't have been a blocker.

Thoughts?

> and that the server could reject a repeat command with the flag if it
> is already serving a previous open-ended request.

Right.

On the other hand, I can imagine that a client might also want to tell
the server that it is no longer interested in an outstanding request. In
such a case, it should be able to cancel it.

-- 
Could you people please use IRC like normal people?!?

  -- Amaya Rodrigo Sastre, trying to quiet down the buzz in the DebConf 2008
     Hacklab

  reply	other threads:[~2017-11-14 17:38 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-12 10:22 [Qemu-devel] How to online resize qemu disk with nbd protocol? Bob Chen
2017-01-12 14:43 ` Eric Blake
2017-01-12 15:44   ` [Qemu-devel] [Nbd] " Alex Bligh
2017-01-12 16:54     ` [Qemu-devel] [Qemu-block] " Stefan Hajnoczi
2017-01-12 17:57       ` Bob Chen
2017-01-12 18:45         ` Eric Blake
2017-01-12 18:56           ` Alex Bligh
2017-01-14 14:48             ` [Qemu-devel] [Nbd] [Qemu-block] " Wouter Verhelst
2017-01-14 15:30               ` Alex Bligh
2017-01-14 14:45           ` Wouter Verhelst
2017-01-16 19:36             ` Eric Blake
2017-01-18  8:01               ` Wouter Verhelst
2017-01-22 10:25                 ` Bob Chen
2017-01-22 11:43                   ` Wouter Verhelst
2017-01-23 14:54                     ` Eric Blake
2017-01-23 15:27                       ` Alex Bligh
2017-01-25  8:47                       ` Wouter Verhelst
2017-11-14 16:41                       ` Eric Blake
2017-11-14 17:37                         ` Wouter Verhelst [this message]
2017-11-14 19:06                           ` Eric Blake
2017-11-16  9:51                             ` Wouter Verhelst
2017-11-16 15:30                               ` Eric Blake
2017-11-16 16:20                                 ` Wouter Verhelst
2017-11-23 11:42                                   ` Wouter Verhelst

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=20171114173745.egvtklxyrcprlcdn@grep.be \
    --to=w@uter.be \
    --cc=a175818323@gmail.com \
    --cc=eblake@redhat.com \
    --cc=nbd@other.debian.org \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@gmail.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).