fstests.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* generic/495: swap on sparse file over NFS
@ 2019-09-23 20:00 J. Bruce Fields
  2019-09-23 20:21 ` Darrick J. Wong
  0 siblings, 1 reply; 2+ messages in thread
From: J. Bruce Fields @ 2019-09-23 20:00 UTC (permalink / raw)
  To: fstests; +Cc: linux-nfs

I'm updating to a newer xfstests and seeing:

generic/495     - output mismatch (see
/root/xfstests-dev/results//generic/495.out.bad)
    --- tests/generic/495.out   2019-09-18 17:28:00.834721480 -0400
    +++ /root/xfstests-dev/results//generic/495.out.bad 2019-09-20 13:34:01.1568
89741 -0400
    @@ -1,5 +1,4 @@
     QA output created by 495
     File with holes
    -swapon: Invalid argument
     Empty swap file (only swap header)
     swapon: Invalid argument

If I understand correctly, it's requiring swapon to fail on a sparse
file, which isn't going to happen on NFS, where the sparsenes of the
file isn't really the client's concern.

Is it really correct to *require* swapon to fail in this case?

--b.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: generic/495: swap on sparse file over NFS
  2019-09-23 20:00 generic/495: swap on sparse file over NFS J. Bruce Fields
@ 2019-09-23 20:21 ` Darrick J. Wong
  0 siblings, 0 replies; 2+ messages in thread
From: Darrick J. Wong @ 2019-09-23 20:21 UTC (permalink / raw)
  To: J. Bruce Fields; +Cc: fstests, linux-nfs

On Mon, Sep 23, 2019 at 04:00:36PM -0400, J. Bruce Fields wrote:
> I'm updating to a newer xfstests and seeing:
> 
> generic/495     - output mismatch (see
> /root/xfstests-dev/results//generic/495.out.bad)
>     --- tests/generic/495.out   2019-09-18 17:28:00.834721480 -0400
>     +++ /root/xfstests-dev/results//generic/495.out.bad 2019-09-20 13:34:01.1568
> 89741 -0400
>     @@ -1,5 +1,4 @@
>      QA output created by 495
>      File with holes
>     -swapon: Invalid argument
>      Empty swap file (only swap header)
>      swapon: Invalid argument
> 
> If I understand correctly, it's requiring swapon to fail on a sparse
> file, which isn't going to happen on NFS, where the sparsenes of the
> file isn't really the client's concern.

It looks that way to me... :)

> Is it really correct to *require* swapon to fail in this case?

Hm.  TBH I was expecting an fpunch call or something to guarantee that
we even /have/ a sparse file, since (for all we know) a filesystem could
interpret "truncate up" to imply that blocks should be speculatively
allocated all the way to the new EOF.

But no, I wouldn't expect swap-over-NFS to know or care if the file is
sparse on the server.  (Based on my limited knowledge of how that even
works...)

--D

> --b.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-09-23 20:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-23 20:00 generic/495: swap on sparse file over NFS J. Bruce Fields
2019-09-23 20:21 ` Darrick J. Wong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).