Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 17 Jan 2025 16:03:08 -0800
From:      Rick Macklem <rick.macklem@gmail.com>
To:        Alan Somers <asomers@freebsd.org>
Cc:        Cedric Blancher <cedric.blancher@gmail.com>, freebsd-hackers@freebsd.org
Subject:   Re: WRITE_SAME support in FreeBSD nfsd NFSv4.1 mode?
Message-ID:  <CAM5tNy4DmgPoKWRONv86v%2BOxEjX0bK4--tcXnWmtOQN96aaaQA@mail.gmail.com>
In-Reply-To: <CAOtMX2jVjMsDdE_E=kZg2OHUbhq=XzRuu1YEowyQXkyg%2Bx7qXg@mail.gmail.com>
References:  <CAAvCNcD1CziGxmgyzyWix5ADsDXRpkbFUM32H9nEji9kR%2BVc-Q@mail.gmail.com> <CAOtMX2i29F8NU493v81ggsdcprr7iifuD1aivaxsULxZrYt1tA@mail.gmail.com> <CALXu0UcP5WR_gV000akarzDxGap70jJwNaf7_BgKgVVU0S2bzg@mail.gmail.com> <CAOtMX2jVjMsDdE_E=kZg2OHUbhq=XzRuu1YEowyQXkyg%2Bx7qXg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Jan 12, 2025 at 1:18=E2=80=AFPM Alan Somers <asomers@freebsd.org> w=
rote:
>
> On Sun, Jan 12, 2025 at 12:23=E2=80=AFAM Cedric Blancher
> <cedric.blancher@gmail.com> wrote:
> >
> > On Fri, 10 Jan 2025 at 16:02, Alan Somers <asomers@freebsd.org> wrote:
> > >
> > > On Thu, Jan 9, 2025 at 5:31=E2=80=AFPM Dan Shelton <dan.f.shelton@gma=
il.com> wrote:
> > > >
> > > > Hello!
> > > >
> > > > Does FreeBSD nfsd support the WRITE_SAME request in NFSv4.1 mode?
> > > >
> > > > Dan
> > > > --
> > > > Dan Shelton - Cluster Specialist Win/Lin/Bsd
> > >
> > > Out of curiosity, what is your use case?
> >
> > As discussed in the linux-nfs@ list, is a typical "big data" and
> > database accelerator, for example fast pattern fill (1 WRITE_SAME
> > command over the write, compared to <n> commands with data block,
> > where <n> is typically > 200 average), or just zero fill for blocks.
> > It's basically reducing network traffic dramatically.
> >
> > Windows SMB 3.0 already supports that, and is a main selling point for
> > M$ to keep database people on the W$ platform. They even added several
> > Windows syscalls like
> > https://learn.microsoft.com/en-us/windows/win32/api/winioctl/ni-winioct=
l-fsctl_set_zero_data
> >
> > Ced
>
> I understand why WRITE SAME would greatly reduce network traffic
> compared to writing the same data n times.  But my question is, what
> real application requires that, where the data isn't simply all-zeros?
>  Are there database operations that require writing the same non-zero
> pattern to multiple blocks?
You might find the discussion on the linux-nfs@vger.kernel.org
mailing list interesting.
It is under this subject line:
[LSF/MM/BPF TOPIC] Implementing the NFS v4.2 WRITE_SAME operation: VFS
or NFS ioctl() ?

Although there is no consensus, it seems to me that there is not a lot
of use for anything beyond zeroing blocks.
Unfortunately a WRITE_SAME implementation needs to do a lot more
that zero blocks.

I am holding off on any server implementation until there is an apparent ne=
ed.

rick

>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAM5tNy4DmgPoKWRONv86v%2BOxEjX0bK4--tcXnWmtOQN96aaaQA>