On 03/30/17 20:34, Ralph Corderoy wrote: >>> I think it would be a good idea to add an option to tell tar whether >>> to use POSIX_FADV_NOREUSE, POSIX_FADV_DONTNEED, or neither, since >>> there may be cases where any of the three possibilities is best. [...] > I often want to run tar, sha1sum, grep, etc., on a huge file knowing > that I won't do it again soon and I don't want it bullying the nice > working-set cache out the door. It seems crazy every command has to add > options to twiddle POSIX_FADV_NOREUSE, like dd(1)'s nocache [io]flag > IIRC. We have stdbuf(1). Perhaps a similar approach can be used to > affect command, even if it can't work in all cases. > > fadvise --noreuse sha1sum big.foo
FWIW, there is https://github.com/Feh/nocache which I use in a tar wrapper script for the backup software. Yours, Uwe