1ef94b186SMiklos Szerediconfig OVERLAY_FS 2e9be9d5eSMiklos Szeredi tristate "Overlay filesystem support" 372d42504SArnd Bergmann select EXPORTFS 4e9be9d5eSMiklos Szeredi help 5e9be9d5eSMiklos Szeredi An overlay filesystem combines two filesystems - an 'upper' filesystem 6e9be9d5eSMiklos Szeredi and a 'lower' filesystem. When a name exists in both filesystems, the 7e9be9d5eSMiklos Szeredi object in the 'upper' filesystem is visible while the object in the 8e9be9d5eSMiklos Szeredi 'lower' filesystem is either hidden or, in the case of directories, 9e9be9d5eSMiklos Szeredi merged with the 'upper' object. 10e9be9d5eSMiklos Szeredi 11e9be9d5eSMiklos Szeredi For more information see Documentation/filesystems/overlayfs.txt 12688ea0e5SMiklos Szeredi 13688ea0e5SMiklos Szerediconfig OVERLAY_FS_REDIRECT_DIR 14688ea0e5SMiklos Szeredi bool "Overlayfs: turn on redirect dir feature by default" 15688ea0e5SMiklos Szeredi depends on OVERLAY_FS 16688ea0e5SMiklos Szeredi help 17688ea0e5SMiklos Szeredi If this config option is enabled then overlay filesystems will use 18688ea0e5SMiklos Szeredi redirects when renaming directories by default. In this case it is 19688ea0e5SMiklos Szeredi still possible to turn off redirects globally with the 20688ea0e5SMiklos Szeredi "redirect_dir=off" module option or on a filesystem instance basis 21688ea0e5SMiklos Szeredi with the "redirect_dir=off" mount option. 22688ea0e5SMiklos Szeredi 23688ea0e5SMiklos Szeredi Note, that redirects are not backward compatible. That is, mounting 24688ea0e5SMiklos Szeredi an overlay which has redirects on a kernel that doesn't support this 25688ea0e5SMiklos Szeredi feature will have unexpected results. 2602bcd157SAmir Goldstein 2736cd95dfSMiklos Szeredi If unsure, say N. 2836cd95dfSMiklos Szeredi 29438c84c2SMiklos Szerediconfig OVERLAY_FS_REDIRECT_ALWAYS_FOLLOW 30438c84c2SMiklos Szeredi bool "Overlayfs: follow redirects even if redirects are turned off" 31438c84c2SMiklos Szeredi default y 32438c84c2SMiklos Szeredi depends on OVERLAY_FS 33438c84c2SMiklos Szeredi help 34438c84c2SMiklos Szeredi Disable this to get a possibly more secure configuration, but that 35438c84c2SMiklos Szeredi might not be backward compatible with previous kernels. 36438c84c2SMiklos Szeredi 3736cd95dfSMiklos Szeredi If backward compatibility is not an issue, then it is safe and 3836cd95dfSMiklos Szeredi recommended to say N here. 3936cd95dfSMiklos Szeredi 40438c84c2SMiklos Szeredi For more information, see Documentation/filesystems/overlayfs.txt 41438c84c2SMiklos Szeredi 4236cd95dfSMiklos Szeredi If unsure, say Y. 4336cd95dfSMiklos Szeredi 4402bcd157SAmir Goldsteinconfig OVERLAY_FS_INDEX 4502bcd157SAmir Goldstein bool "Overlayfs: turn on inodes index feature by default" 4602bcd157SAmir Goldstein depends on OVERLAY_FS 4702bcd157SAmir Goldstein help 4802bcd157SAmir Goldstein If this config option is enabled then overlay filesystems will use 4902bcd157SAmir Goldstein the inodes index dir to map lower inodes to upper inodes by default. 5002bcd157SAmir Goldstein In this case it is still possible to turn off index globally with the 5102bcd157SAmir Goldstein "index=off" module option or on a filesystem instance basis with the 5202bcd157SAmir Goldstein "index=off" mount option. 5302bcd157SAmir Goldstein 5402bcd157SAmir Goldstein The inodes index feature prevents breaking of lower hardlinks on copy 5502bcd157SAmir Goldstein up. 5602bcd157SAmir Goldstein 5760b86642SAmir Goldstein Note, that the inodes index feature is not backward compatible. 5860b86642SAmir Goldstein That is, mounting an overlay which has an inodes index on a kernel 5960b86642SAmir Goldstein that doesn't support this feature will have unexpected results. 60f168f109SAmir Goldstein 6136cd95dfSMiklos Szeredi If unsure, say N. 6236cd95dfSMiklos Szeredi 63f168f109SAmir Goldsteinconfig OVERLAY_FS_NFS_EXPORT 64f168f109SAmir Goldstein bool "Overlayfs: turn on NFS export feature by default" 65f168f109SAmir Goldstein depends on OVERLAY_FS 66f168f109SAmir Goldstein depends on OVERLAY_FS_INDEX 67f168f109SAmir Goldstein help 68f168f109SAmir Goldstein If this config option is enabled then overlay filesystems will use 69f168f109SAmir Goldstein the inodes index dir to decode overlay NFS file handles by default. 70f168f109SAmir Goldstein In this case, it is still possible to turn off NFS export support 71f168f109SAmir Goldstein globally with the "nfs_export=off" module option or on a filesystem 72f168f109SAmir Goldstein instance basis with the "nfs_export=off" mount option. 73f168f109SAmir Goldstein 74f168f109SAmir Goldstein The NFS export feature creates an index on copy up of every file and 75f168f109SAmir Goldstein directory. This full index is used to detect overlay filesystems 76f168f109SAmir Goldstein inconsistencies on lookup, like redirect from multiple upper dirs to 77f168f109SAmir Goldstein the same lower dir. The full index may incur some overhead on mount 78f168f109SAmir Goldstein time, especially when verifying that directory file handles are not 79f168f109SAmir Goldstein stale. 80f168f109SAmir Goldstein 81f168f109SAmir Goldstein Note, that the NFS export feature is not backward compatible. 82f168f109SAmir Goldstein That is, mounting an overlay which has a full index on a kernel 83f168f109SAmir Goldstein that doesn't support this feature will have unexpected results. 8436cd95dfSMiklos Szeredi 8536cd95dfSMiklos Szeredi Most users should say N here and enable this feature on a case-by- 8636cd95dfSMiklos Szeredi case basis with the "nfs_export=on" mount option. 8736cd95dfSMiklos Szeredi 8836cd95dfSMiklos Szeredi Say N unless you fully understand the consequences. 89