Re: [PATCH v15 3/9] fuse: implement ioctls to manage backing files

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

 



On Wed, Feb 28, 2024 at 5:01 PM Miklos Szeredi <miklos@xxxxxxxxxx> wrote:
>
> On Wed, 28 Feb 2024 at 15:32, Jens Axboe <axboe@xxxxxxxxx> wrote:
> >
> > On 2/28/24 4:28 AM, Amir Goldstein wrote:
>
> > > Are fixed files visible to lsof?
> >
> > lsof won't show them, but you can read the fdinfo of the io_uring fd to
> > see them. Would probably be possible to make lsof find and show them
> > too, but haven't looked into that.
>
> Okay, that approach could be used with fuse as well.  This isn't
> perfect, but we can think improving the interface for both.
>
> > > Do they get accounted in rlimit? of which user?
> >
> > The fixed file table is limited in size by RLIMIT_NOFILE by the user
> > that registers it.
>
> That's different for fuse as the server wouldn't register the whole
> file table in one go.  The number of used slots could be limited by
> RLIMIT_NOFILE, I think.
>

Yes. We can limit the number of backing id slots, which is the
number of FUSE_DEV_IOC_BACKING_OPEN for whom the server
did not call FUSE_DEV_IOC_BACKING_CLOSE, and we can easily
display the backing files in backing_files_map, but we also have
inode attached backing file, whose lifetime is that of the fuse files.

Those all harder to iterate and harder to limit, because the server
cannot close/revoke them.
OTOH, we could treat the inode attached backing files same as the
overlayfs backing files - worst case they only double the number of
files in the system.

We can probably keep them also in backing_files_map so we can iterate
them, but maybe let's see how the basic feature works first...

Thanks,
Amir.





[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