Re: [PATCH] fs: fix possible inconsistent mount device

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

 



Hi, Christoph!

在 2022/08/13 15:15, Christoph Hellwig 写道:
On Sat, Aug 13, 2022 at 03:09:58PM +0800, Yu Kuai wrote:
Thanks for your reply. Do you think it's better to remove the rename
support from dm? Or it's better to add such limit?

It will probably be hard to entirely remove it.  But documentation
and a rate limited warning discouraging it seems like a good idea.
.


I just found that not just rename, mount concurrent with device
remove/create can trigger this problem as well:

t1:                       t2
// create dm-0 with name test1
// mount /dev/mapper/test1
mount_bdev
 blkdev_get_by_path
  lookup_bdev
                          // remove dm-0
                          // create dm-0 with different name test2
  blkdev_get_by_dev
  // succeed

Do you think it's ok to add such checking to prevent this problem?

Thanks,
Kuai




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

  Powered by Linux