Miklos Szeredi | ef94b18 | 2014-11-20 16:39:59 +0100 | [diff] [blame] | 1 | config OVERLAY_FS |
Miklos Szeredi | e9be9d5 | 2014-10-24 00:14:38 +0200 | [diff] [blame] | 2 | tristate "Overlay filesystem support" |
Arnd Bergmann | 72d4250 | 2017-05-11 13:34:29 +0200 | [diff] [blame] | 3 | select EXPORTFS |
Miklos Szeredi | e9be9d5 | 2014-10-24 00:14:38 +0200 | [diff] [blame] | 4 | help |
| 5 | An overlay filesystem combines two filesystems - an 'upper' filesystem |
| 6 | and a 'lower' filesystem. When a name exists in both filesystems, the |
| 7 | object in the 'upper' filesystem is visible while the object in the |
| 8 | 'lower' filesystem is either hidden or, in the case of directories, |
| 9 | merged with the 'upper' object. |
| 10 | |
| 11 | For more information see Documentation/filesystems/overlayfs.txt |
Miklos Szeredi | 688ea0e | 2016-12-16 11:02:57 +0100 | [diff] [blame] | 12 | |
| 13 | config OVERLAY_FS_REDIRECT_DIR |
| 14 | bool "Overlayfs: turn on redirect dir feature by default" |
| 15 | depends on OVERLAY_FS |
| 16 | help |
| 17 | If this config option is enabled then overlay filesystems will use |
| 18 | redirects when renaming directories by default. In this case it is |
| 19 | still possible to turn off redirects globally with the |
| 20 | "redirect_dir=off" module option or on a filesystem instance basis |
| 21 | with the "redirect_dir=off" mount option. |
| 22 | |
| 23 | Note, that redirects are not backward compatible. That is, mounting |
| 24 | an overlay which has redirects on a kernel that doesn't support this |
| 25 | feature will have unexpected results. |
Amir Goldstein | 02bcd15 | 2017-06-21 15:28:36 +0300 | [diff] [blame] | 26 | |
Miklos Szeredi | 438c84c | 2017-12-11 11:28:10 +0100 | [diff] [blame] | 27 | config OVERLAY_FS_REDIRECT_ALWAYS_FOLLOW |
| 28 | bool "Overlayfs: follow redirects even if redirects are turned off" |
| 29 | default y |
| 30 | depends on OVERLAY_FS |
| 31 | help |
| 32 | Disable this to get a possibly more secure configuration, but that |
| 33 | might not be backward compatible with previous kernels. |
| 34 | |
| 35 | For more information, see Documentation/filesystems/overlayfs.txt |
| 36 | |
Amir Goldstein | 02bcd15 | 2017-06-21 15:28:36 +0300 | [diff] [blame] | 37 | config OVERLAY_FS_INDEX |
| 38 | bool "Overlayfs: turn on inodes index feature by default" |
| 39 | depends on OVERLAY_FS |
| 40 | help |
| 41 | If this config option is enabled then overlay filesystems will use |
| 42 | the inodes index dir to map lower inodes to upper inodes by default. |
| 43 | In this case it is still possible to turn off index globally with the |
| 44 | "index=off" module option or on a filesystem instance basis with the |
| 45 | "index=off" mount option. |
| 46 | |
| 47 | The inodes index feature prevents breaking of lower hardlinks on copy |
| 48 | up. |
| 49 | |
Amir Goldstein | 60b8664 | 2018-01-10 23:15:21 +0200 | [diff] [blame] | 50 | Note, that the inodes index feature is not backward compatible. |
| 51 | That is, mounting an overlay which has an inodes index on a kernel |
| 52 | that doesn't support this feature will have unexpected results. |
Amir Goldstein | f168f10 | 2018-01-19 11:26:53 +0200 | [diff] [blame^] | 53 | |
| 54 | config OVERLAY_FS_NFS_EXPORT |
| 55 | bool "Overlayfs: turn on NFS export feature by default" |
| 56 | depends on OVERLAY_FS |
| 57 | depends on OVERLAY_FS_INDEX |
| 58 | help |
| 59 | If this config option is enabled then overlay filesystems will use |
| 60 | the inodes index dir to decode overlay NFS file handles by default. |
| 61 | In this case, it is still possible to turn off NFS export support |
| 62 | globally with the "nfs_export=off" module option or on a filesystem |
| 63 | instance basis with the "nfs_export=off" mount option. |
| 64 | |
| 65 | The NFS export feature creates an index on copy up of every file and |
| 66 | directory. This full index is used to detect overlay filesystems |
| 67 | inconsistencies on lookup, like redirect from multiple upper dirs to |
| 68 | the same lower dir. The full index may incur some overhead on mount |
| 69 | time, especially when verifying that directory file handles are not |
| 70 | stale. |
| 71 | |
| 72 | Note, that the NFS export feature is not backward compatible. |
| 73 | That is, mounting an overlay which has a full index on a kernel |
| 74 | that doesn't support this feature will have unexpected results. |