All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Max Reitz <mreitz@redhat.com>
Cc: Kevin Wolf <kwolf@redhat.com>,
	qemu-devel@nongnu.org, qemu-block@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 1/5] qemu-nbd: Add --pid-file option
Date: Wed, 8 May 2019 10:03:45 +0100	[thread overview]
Message-ID: <20190508090345.GB32552@redhat.com> (raw)
In-Reply-To: <f34fb38c-22dd-1ed3-821d-7c8a9ea8943a@redhat.com>

On Tue, May 07, 2019 at 09:39:01PM +0200, Max Reitz wrote:
> On 07.05.19 21:30, Eric Blake wrote:
> > On 5/7/19 1:36 PM, Max Reitz wrote:
> >> --fork is a bit boring if there is no way to get the child's PID.  This
> >> option helps.
> >>
> >> Signed-off-by: Max Reitz <mreitz@redhat.com>
> >> ---
> >>  qemu-nbd.c    | 29 +++++++++++++++++++++++++++++
> >>  qemu-nbd.texi |  2 ++
> >>  2 files changed, 31 insertions(+)
> >>
> > 
> >> @@ -111,6 +112,7 @@ static void usage(const char *name)
> >>  "                            specify tracing options\n"
> >>  "  --fork                    fork off the server process and exit the parent\n"
> >>  "                            once the server is running\n"
> >> +"  --pid-file=PATH           store the server's process ID in the given file\n"
> > 
> > Should --pid-file imply --fork, or be an error if --fork was not
> > supplied? As coded, it writes a pid file regardless of --fork, even
> > though it is less obvious that it is useful in that case. I don't have a
> > strong preference (there doesn't seem to be a useful consensus on what
> > forking daemons should do), but it would at least be worth documenting
> > the intended action (even if that implies a tweak to the patch to match
> > the intent).
> 
> I think the documentation is pretty clear.  It stores the server's PID,
> whether it has been forked or not.
> 
> I don't think we would gain anything from forbidding --pid-file without
> --fork, would we?

Indeed, use of --pid-file should be independant of --fork, as a mgmt app
may have already forked it into the background, and merely want to get
the pidfile

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 :|


  parent reply	other threads:[~2019-05-08  9:10 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-07 18:36 [Qemu-devel] [PATCH 0/5] iotests: Let 233 run concurrently Max Reitz
2019-05-07 18:36 ` [Qemu-devel] [PATCH 1/5] qemu-nbd: Add --pid-file option Max Reitz
2019-05-07 19:30   ` Eric Blake
2019-05-07 19:39     ` Max Reitz
2019-05-07 19:51       ` Eric Blake
2019-05-07 20:09         ` Max Reitz
2019-05-08  9:03       ` Daniel P. Berrangé [this message]
2019-05-08  9:01   ` Daniel P. Berrangé
2019-05-08 12:42     ` Max Reitz
2019-05-07 18:36 ` [Qemu-devel] [PATCH 2/5] iotests.py: Add qemu_nbd_early_pipe() Max Reitz
2019-05-07 19:34   ` Eric Blake
2019-05-07 18:36 ` [Qemu-devel] [PATCH 3/5] qemu-nbd: Do not close stderr Max Reitz
2019-05-07 19:47   ` Eric Blake
2019-05-07 18:36 ` [Qemu-devel] [PATCH 4/5] iotests: Use qemu-nbd's --pid-file Max Reitz
2019-05-07 19:53   ` Eric Blake
2019-05-07 20:08     ` Max Reitz
2019-05-07 18:36 ` [Qemu-devel] [PATCH 5/5] iotests: Let 233 run concurrently Max Reitz
2019-05-07 20:38   ` Eric Blake
2019-05-07 20:49     ` Max Reitz

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=20190508090345.GB32552@redhat.com \
    --to=berrange@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.