[Devel] [PATCH RHEL COMMIT] configs: Set overlayfs nfs_export option to true

Konstantin Khorenko khorenko at virtuozzo.com
Mon Oct 4 20:39:06 MSK 2021


The commit is pushed to "branch-rh9-5.14.vz9.1.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after ark-5.14
------>
commit 1d2a838ec24ab0f561d8e52b8eab5b3e9cd735bc
Author: Valeriy Vdovin <valeriy.vdovin at virtuozzo.com>
Date:   Mon Oct 4 20:39:06 2021 +0300

    configs: Set overlayfs nfs_export option to true
    
    +CONFIG_OVERLAY_FS_INDEX=y
    +CONFIG_OVERLAY_FS_NFS_EXPORT=y
    
    Docker uses overlayfs. Lately, I've been testing checkpoint/restore of
    fs notifications that were setup on top of overlayfs. I've found out
    that criu is not able to dump opened file descriptors of fanotify when
    nfs_export parameter is off.
    
    The details of that problem: at checkpoint/dump criu wants to dump
    fanotify fd and uses 'open_by_handle_at' with fhandle of the subject
    descriptor. Kernel needs to decode fhandle to convert it to inode, for
    that it uses mnt->mnt_sb->s_export_op->fh_to_dentry.
    
    For overlayfs mount s_export_op is only filled with valid exportfs
    function if nfs_export flag is true. nfs_export in its turn depends on
    index=on option.
    
    One way to enable them is to extend mount options with string
    "nfs_export=on,index=on" during call to mount. Another way which we
    discussed - is to tune defaults for both values to true.
    
    https://jira.sw.ru/browse/PSBM-104961
    
    Signed-off-by: Valeriy Vdovin <valeriy.vdovin at virtuozzo.com>
    
    (cherry picked from vz8 commit 7fe31a28bad084949cd927fbce553d9152631e15)
    Signed-off-by: Andrey Zhadchenko <andrey.zhadchenko at virtuozzo.com>
---
 redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_INDEX      | 1 +
 redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_NFS_EXPORT | 1 +
 2 files changed, 2 insertions(+)

diff --git a/redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_INDEX b/redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_INDEX
new file mode 100644
index 000000000000..c61cab2ace07
--- /dev/null
+++ b/redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_INDEX
@@ -0,0 +1 @@
+CONFIG_OVERLAY_FS_INDEX=y
diff --git a/redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_NFS_EXPORT b/redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_NFS_EXPORT
new file mode 100644
index 000000000000..a3fcd01173e6
--- /dev/null
+++ b/redhat/configs/custom-overrides/generic/CONFIG_OVERLAY_FS_NFS_EXPORT
@@ -0,0 +1 @@
+CONFIG_OVERLAY_FS_NFS_EXPORT=y


More information about the Devel mailing list