Re: Sparse file support in FreeBSD NFSv4.2 server

From: Andriy Gapon <avg_at_FreeBSD.org>
Date: Tue, 13 May 2025 05:09:59 UTC
On 12/05/2025 17:38, Rick Macklem wrote:
> On Mon, May 12, 2025 at 2:40 AM Aurélien Couderc
>> Solaris has fnctl(F_ALLOCSP,...), so this should work on ZFS.

There is a jump from something exists to something works for every filesystem.

> Well, I'm not a ZFS guy, but here is what I understood from the ZFS
> folk w.r.t. this:
One can also check illumos source code.  F_ALLOCSP is implemented only for UFS.

zfs_space() has this:

/*
  * Free or allocate space in a file.  Currently, this function only
  * supports the `F_FREESP' command.
...
  */
...
         if (cmd != F_FREESP) {
                 ZFS_EXIT(zfsvfs);
                 return (SET_ERROR(EINVAL));
         }


-- 
Andriy Gapon