[bug?][read-ahead] when cache is invalid, should destroy all cache in the same inode_t?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

now the cache is bind to fd_t, and when there is a write command, only
the cache in this fd_t is mark dirty. I think this scheme has problem
in the real world.

Consider there are process A and B open the same file, A write data to
a file and B read data from that file after A notify B the data is
ready. In this case, A and B have different fd_t, and A's write
operation will not trigger B's cache dirty. so B read the dirty data
from cache. What do you think? Or did I make any mistake on this
problem?

some operations in read-ahead is affected by this issue, including (at
least) ra_writev, ra_truncate, ra_ftruncate.

write-behind maybe affected by the same issue, but I am not very clear
on this. at least wb_truncate, wb_stat, wb_utimens has a bug, it
should trigger the wb_sync for all the fd_t, not only the first fd_t.

Best Regards,
 LI Daobing




[Index of Archives]     [Gluster Users]     [Ceph Users]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux