Re: [PATCH v4 00/15] fanotify: add support for more event types

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

 



> > TBH, I think that the ATTRIB event just before renaming over an empty
> > dir is grossly uninteresting. Not to mention that there is no such event
> > on rmdir() nor on unlink(), even if nlink is decremented to non zero.
>
> But you won't get other event telling you that some dir entry got actually
> overwritten by the rename, will you? Note that the inode need not get
> deleted if it has other links to it. Actually sending fsnotify_nameremove()
> would look like a more sensible choice but that ship has already sailed...
>

You get a MOVED_TO event on the modified dir.
So long as we do not report dirent filenames, that is just as informative as
getting ATTRIB event on the modified dir (MOVED_TO has greater chance
to imply overwrite than ATTRIB does).

The inode of an overwritten empty directory will produce DELETE_SELF
event, because empty directory cannot have links to it.

I am not saying ATTRIB event for decremented nlink on non dir doesn't
make sense. I am saying ATTRIB|ISDIR event in that case doesn't make
a whole lot of sense. Anyway I am not changing this now.

Thanks,
Amir.



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux