All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Richard W.M. Jones" <rjones@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Kevin Wolf <kwolf@redhat.com>,
	codonell@redhat.com,
	"Dr. David Alan Gilbert" <dgilbert@redhat.com>,
	Qemu-block <qemu-block@nongnu.org>,
	QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH] block/raw-posix: Open file descriptor O_RDWR to work around glibc posix_fallocate emulation issue.
Date: Fri, 2 Oct 2015 15:43:46 +0100	[thread overview]
Message-ID: <20151002144346.GP29330@redhat.com> (raw)
In-Reply-To: <CAFEAcA_+OtX0o4K5meqQtnTNhESrLpw8pGoj2d433rYieSOXMA@mail.gmail.com>

On Fri, Oct 02, 2015 at 03:36:04PM +0100, Peter Maydell wrote:
> On 29 September 2015 at 16:54, Richard W.M. Jones <rjones@redhat.com> wrote:
> >   https://bugzilla.redhat.com/show_bug.cgi?id=1265196
> >
> > The following command fails on an NFS mountpoint:
> >
> >   $ qemu-img create -f qcow2 -o preallocation=falloc disk.img 262144
> >   Formatting 'disk.img', fmt=qcow2 size=262144 encryption=off cluster_size=65536 preallocation='falloc' lazy_refcounts=off
> >   qemu-img: disk.img: Could not preallocate data for the new file: Bad file descriptor
> >
> > The reason turns out to be because NFS doesn't support the
> > posix_fallocate call.  glibc emulates it instead.  However glibc's
> > emulation involves using the pread(2) syscall.  The pread syscall
> > fails with EBADF if the file descriptor is opened without the read
> > open-flag (ie. open (..., O_WRONLY)).
> >
> > I contacted glibc upstream about this, and their response is here:
> >
> >   https://bugzilla.redhat.com/show_bug.cgi?id=1265196#c9
> 
> "You are not authorized to access bug #1265196."
> 
> Any chance of a working URL if we're going to immortalize it
> in QEMU's git log?

Sorry about that.  I have now made the bug public -- there was
absolutely no reason why it was private before.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
libguestfs lets you edit virtual machines.  Supports shell scripting,
bindings from many languages.  http://libguestfs.org

      reply	other threads:[~2015-10-02 14:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-29 15:54 [Qemu-devel] [PATCH] block/raw-posix: Open file descriptor O_RDWR to work around glibc posix_fallocate emulation issue Richard W.M. Jones
2015-09-30 11:42 ` Kevin Wolf
2015-09-30 20:44 ` [Qemu-devel] [Qemu-block] " Jeff Cody
2015-10-01  3:36 ` [Qemu-devel] " Eric Blake
2015-10-02 14:36 ` Peter Maydell
2015-10-02 14:43   ` Richard W.M. Jones [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=20151002144346.GP29330@redhat.com \
    --to=rjones@redhat.com \
    --cc=codonell@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=peter.maydell@linaro.org \
    --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.