* How to reproduce: /tmp % cat a.c #define _GNU_SOURCE 1 #include <limits.h> #include <stdio.h> #include <unistd.h> #include <fcntl.h> int main(void) { int pipefd[2]; pipe(pipefd); for (;;) { sleep(1); write(pipefd[1], "Hello world\n", 12); splice(pipefd[0], NULL, 1, NULL, INT_MAX, 0); } } /tmp % gcc a.c /tmp % touch a.txt /tmp % ./a.out > a.txt & tail -f a.txt * Expected result: tail prints "Hello world" every second. * Actual result: btrfs: Works as expected; ext4/tmpfs: tail blocks on inotify forever and prints nothing.
So this isn't a problem with current kernel (I tested 3.17-rc5) anymore. I believe it got fixed by Al Viro's splice rewrite so 3.16 and newer kernels should have the problem fixed.
I still see this issue on kernel versions 4.4 and 4.9. But not on 4.15.