Re: d_add and dentry leak

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

 



On Thu, Feb 21, 2019 at 03:45:06PM +0800, Fam Zheng wrote:
> We’ve noticed an issue that frequent open,close,open,close... of /dev/ptmx eventually causes soft lockup.
> 
> Here is a summary of what happened.
> 
> Upon user opening /dev/ptmx, devpts_pty_new calls d_alloc_name and d_add, the new dentry is inserted into dcache_hashtable.
> 
> Later when closing, devpts_pty_kill calls d_delete and dput,

... since it looks like a normal negative dentry, to be eventually
evicted upon memory pressure.  That's not the worst problem in
there, actually - consider
touch /tmp/a
mount --bind /tmp/a /dev/pts/<number>
followed by devpts_pty_kill() taking that sucker out...



[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