[Devel] [PATCH rh7] ve/fuse: allow to mount fuse in non-init user_ns
Andrey Ryabinin
aryabinin at virtuozzo.com
Mon Jun 25 19:20:55 MSK 2018
On 06/20/2018 01:09 PM, Konstantin Khorenko wrote:
> RHEL7.5 enforced sget() (sget_userns() in fact) to check the
> FS_USERNS_MOUNT flag on fs_flags, fuse lacks the flag and
> thus we are unable to mount fuse inside a Container.
>
> Fix this - allow fuse to be mounted in non-init user namespaces.
>
> Fixes: 371904f01f05 ("fuse: virtualize file system")
> https://jira.sw.ru/browse/PSBM-85886
>
> Signed-off-by: Konstantin Khorenko <khorenko at virtuozzo.com>
Acked-by: Andrey Ryabinin <aryabinin at virtuozzo.com>
> ---
> fs/fuse/inode.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c
> index 8a9fa0d7997d..07b526818939 100644
> --- a/fs/fuse/inode.c
> +++ b/fs/fuse/inode.c
> @@ -1445,7 +1445,7 @@ static void fuse_kill_sb_anon(struct super_block *sb)
> static struct file_system_type fuse_fs_type = {
> .owner = THIS_MODULE,
> .name = "fuse",
> - .fs_flags = FS_HAS_SUBTYPE | FS_VIRTUALIZED,
> + .fs_flags = FS_HAS_SUBTYPE | FS_VIRTUALIZED | FS_USERNS_MOUNT,
> .mount = fuse_mount,
> .kill_sb = fuse_kill_sb_anon,
> };
>
More information about the Devel
mailing list