]> git.ipfire.org Git - thirdparty/man-pages.git/commit
posix_fallocate.3: Mention glibc emulation caveats
authorCarlos O'Donell <carlos@redhat.com>
Fri, 2 Oct 2015 04:17:43 +0000 (00:17 -0400)
committerMichael Kerrisk <mtk.manpages@gmail.com>
Mon, 5 Oct 2015 08:47:47 +0000 (09:47 +0100)
commita74bc4c9e44e3ec1e8c9b8487f07bc543ed7d0ef
treec93e3ece67c8608a7423ca5367a67f8ad07dff2a
parent422dd47fd8d1c27371a0260e81e20b78dd24264a
posix_fallocate.3: Mention glibc emulation caveats

When the glibc implementation of posix_fallocate detects
that the underlying filesystem does not support fallocate()
it uses an emulation function to attempt to allocate the
space requested. The most common case is calling
posix_fallocatei() for a file that is on NFS where the
NFS server is not new enough to support the recent fallocate
extensions. This emulation has various serious caveats that
must be understood in order to use posix_fallocate robustly
on all filesystems. The change documents the caveats in the
glibc implementation.

Lastly, we expand the meaning of EINVAL to match POSIX
2013 (Issue 7). If the underlying filesystem doesn't support
posix_fallocate()i, the implementation can return EINVAL, but
glibc does not do this, it emulates the operation instead.

Signed-off-by: Carlos O'Donell <carlos@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
man3/posix_fallocate.3