It was discovered that with libfuse3 we lost FOPEN_DIRECT_IO flag
on (struct fuse_file)->open_flags. I'm sure that this is the reason
for all the strange bugs that our users met recently.
Fixes:
https://github.com/lxc/lxcfs/issues/565
https://discuss.linuxcontainers.org/t/number-of-cpus-reported-by-proc-stat-fluctuates-causing-issues/15780/14
Signed-off-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com>
if (lxcfs_init_library() < 0)
return NULL;
+#if HAVE_FUSE3
+ cfg->direct_io = 1;
+#endif
+
return fuse_get_context()->private_data;
}