Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

shiftfs incompatible with overlayfs without specific overlayfs version #2

Open
hxx-fetch opened this issue Apr 16, 2020 · 11 comments
Open
Labels
fixed-in-ubuntu Problem is solved in the Ubuntu Distro other-project Report is connected to another project wontfix This won't be fixed workaround-available

Comments

@hxx-fetch
Copy link

There seems to be an additional kernel patch in conjunction with shiftfs when used above overlayfs:

https://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/focal/commit/fs/overlayfs?id=d24b8a547be1578cb5a200ad9ac57a258f0a9de1

So it should be noted in the documentation not to use this dkms in conjunction with overlayfs.

@toby63
Copy link
Owner

toby63 commented Apr 16, 2020

For everyone reading this issue I want to give a summary:

Note: The following information might be outdated.

Problem:
The problem is that overlayfs cannot be used inside a container, when the container software uses shiftfs.
Note: This is only a problem for special use cases, e.g. running Docker with the overlayfs-storage-driver inside an LXD container.

Solution:
A solution is available in form of kernel patches for the overlayfs module (see ubuntu kernel commit).
But these patches are not included in the mainline kernel.
To my knowledge only Ubuntu included them in their kernel.

Main (potential) Workaround:

  • patch the kernel module "overlayfs" via dkms:
    (or more correct: install a modified/patched version of overlayfs via dkms)
    You can use a similar dkms package (such as this one) and try to edit it for overlayfs.
    Note: This approach is untested, so it might not work (e.g. some modules cannot be "managed" with dkms).

Other Workarounds:

  • use Ubuntu:
    Regarding Derivates: it is unknown to me whether Ubuntu derivates (such as mint) include the ubuntu kernel

  • convince your distro's kernel maintainers to include the patches

  • (not recommended) patch the kernel sources and rebuild the kernel manually (this might take a long time to compile)


Original Post:
@hxx-fetch:
You are right.
Although this problem is mentioned in a post I linked to in the Readme (see "Further information on shiftfs"), I agree that I should clarify it here in the Readme too.
Quote from the LXD Forum:

Limitations

The only limitation we’re currently aware of is that shiftfs will prevent the use of overlayfs inside the container. This may break Docker users. If this applies to you, you should stay away from shiftfs for now.

I added a note in the Readme (see commit).

@toby63

This comment has been minimized.

@brauner

This comment has been minimized.

@toby63 toby63 pinned this issue Apr 16, 2020
@toby63

This comment has been minimized.

@toby63 toby63 added documentation Improvements or additions to documentation future/planned might be added/fixed in the future other-project Report is connected to another project workaround-available labels Apr 16, 2020
@brauner

This comment has been minimized.

@toby63

This comment has been minimized.

@toby63 toby63 assigned toby63 and unassigned toby63 Apr 16, 2020
@toby63 toby63 added fixed-in-ubuntu Problem is solved in the Ubuntu Distro help wanted help is appreciated kernel Problem is connected to the linux kernel missing-patch/feature A patch or feature is missing that is included elsewhere labels Apr 17, 2020
@toby63

This comment has been minimized.

@toby63 toby63 removed documentation Improvements or additions to documentation help wanted help is appreciated labels Apr 17, 2020
@toby63

This comment has been minimized.

@toby63 toby63 self-assigned this Apr 22, 2020
@toby63

This comment has been minimized.

@hxx-fetch

This comment has been minimized.

@toby63

This comment has been minimized.

@toby63 toby63 removed their assignment May 1, 2020
@toby63 toby63 added need-tester Proposed solution needs tester. potential-fix A potential fix is available, needs testing and removed other-project Report is connected to another project missing-patch/feature A patch or feature is missing that is included elsewhere labels May 1, 2020
@toby63 toby63 removed the future/planned might be added/fixed in the future label Aug 16, 2020
@toby63 toby63 unpinned this issue Aug 24, 2021
@toby63 toby63 added other-project Report is connected to another project wontfix This won't be fixed and removed kernel Problem is connected to the linux kernel need-tester Proposed solution needs tester. potential-fix A potential fix is available, needs testing labels Aug 26, 2021
@toby63 toby63 changed the title Missing patch for using shiftfs in conjunction with overlayfs shiftfs incompatible with overlayfs without specific overlayfs version Aug 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fixed-in-ubuntu Problem is solved in the Ubuntu Distro other-project Report is connected to another project wontfix This won't be fixed workaround-available
Projects
None yet
Development

No branches or pull requests

3 participants