diff options
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/README.md b/README.md new file mode 100644 index 0000000..c164345 --- /dev/null +++ b/README.md @@ -0,0 +1,9 @@ +# dontneed: tell linux you don't need some files in RAM cache + +Maybe used to prevent swapping about files you write but don't read, like somedump.sql.gz on somelog.1.gz. + + Usage: ./dontneed <path>... + Calls posix_fadvise(fd, 0, 0, POSIX_FADV_DONTNEED) on each <path> + + Tip: you may find all cached files from rootfs with the costly one-liner: + # find / -mount -type f -print0 | xargs -r0 fincore | grep -vE '^ *0B' | sort -hr | uniq | less |