Re: posix_fallocate on ZFS

From: Alan Somers <asomers_at_freebsd.org>
Date: Sat, 10 Feb 2018 16:10:44 -0700
On Sat, Feb 10, 2018 at 3:50 PM, Willem Jan Withagen <wjw_at_digiware.nl>
wrote:

> On 10/02/2018 20:43, Ian Lepore wrote:
>
>> On Sat, 2018-02-10 at 11:24 -0700, Alan Somers wrote:
>>
>>> On Sat, Feb 10, 2018 at 10:28 AM, Willem Jan Withagen
>>> wrote:
>>>
>>>
>>>> Hi,
>>>>
>>>> This has been disabled on ZFS since last November.
>>>> And I do understand the rationale on this.
>>>>
>>>> BUT
>>>>
>>>> I've now upgraded some of my HEAD Ceph test systems and they now fail,
>>>> since Ceph uses posix_fallocate() to allocate space for the
>>>> FileStore-journal.
>>>>
>>>> Is there any expectation that this is going to fixed in any near future?
>>>>
>>>> --WjW
>>>>
>>>> No.  It's fundamentally impossible to support posix_fallocate on a COW
>>> filesystem like ZFS.  Ceph should be taught to ignore an EINVAL result,
>>> since the system call is merely advisory.
>>>
>>> -Alan
>>>
>>
>> Unfortunately, posix documents that the function returns EINVAL only
>> due to bad input parameters, so ignoring that seems like a bad idea.
>>
>> Wouldn't it be better if we returned EOPNOTSUP if that's the actual
>> situation?  That could be safely ignored.
>>
>
> I would probably help in my situation....
>
> And I've been looking at the manpage, but cannot seem to find any
> indication that EINVAL is returned on running it on FreeBSD.
>

It's in the manpage, but only on head.  It hasn't been in any stable
release yet.

https://svnweb.freebsd.org/base/head/lib/libc/sys/posix_fallocate.2?revision=325422&view=markup#l112
Received on Sat Feb 10 2018 - 22:10:48 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:14 UTC