-
Notifications
You must be signed in to change notification settings - Fork 858
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
mount cgroup v2 error (Docker) #9868
Comments
ubuntu 18.04 has the same question ... |
This issue happens right after a force upgrading that caused by #9866. Now I have to doubt the reliability of WSL.
With
|
Please help, have the same issue here... |
Revert to the last release 1.1.3 manually fixed the issue. |
It is working. But The Version use cgroup v1 not v2. When use v2, has the same problem. Now I use |
It still breaks docker buildx https://docs.docker.com/engine/reference/commandline/buildx/
|
@Harry-zklcdc I think this can be closed for now. My issue has gone after I reinstalled the 1.1.6 version from git release and rebooted the system several times. |
I had a similar issue today. Tried the above suggestions, but it did break docker.
Maybe this helps someone. I think its best to treat this as a workaround until the devs figure out the real cause for this issue & provide a fix. |
Any solution? editing the conf file with
the build still fails |
The @nanobyt3 suggestion works for me. |
~~The errors goes away, but it seems that some Docker features still doesn't work. We use Lando here to manage our development environment, and the tool is able to re-create its Traefik proxy, but then fails to create any additional images or containers. It may not be linked to the Docker issue, but as it was working fine yesterday I suspect that what triggered the #9866 issue broke something that is related to this... ~~ Make sure that your tools are up to date, and properly configured. I had a broken local config file 😄 |
I was able to fix this by re-enabling Hyper-V from 'Turn Windows features on or off' in the Control Panel. |
Thanks very much @nanobyt3 , that solved |
@nanobyt3 - you shouldn't need to do that, cgroupv2 should be mounted by default. |
@benhillis Don't change the title. Cgroup v1 on WSL 1.1.3.0 is working perfet. But after upgrading to version 1.1.6.0, cgroup v2 is force loading since prerelease v1.1.5.0. |
I'm using a wsl2 based on amazonlinux2, and updating to 1.1.6.0 via the MS Store broke my docker/minikube setup (it was working with 1.1.3.0). Now I can't run
So there's seems to be some affect from the 1.1.5 change "Do not mount cgroup v1 for WSL2" that is making systemd still operate in legacy mode but other tools like docker/containerd are failing due to some kind of inconsistencies. Is there a way to force systemd to run in unified mode instead of legacy mode? |
@wynnw You can use this. It works for me! |
I'm running with that setting already. |
I have the same issue
|
I'm having the same problem after upgrading to WSL2 1.1.6. |
Download and install the .msixbundle file on the release page to revert. |
And if that should not work, then uninstall WSL2 from start menu => Settings => Add or remove programs => Windows Subsystem for Linux => remove and then install the msixbundle for 1.1.3 again. |
I got the same problem yesterday |
@benhillis, yes, cgroup2 mounts by default. But, according to what is mentioned in the SO post (https://stackoverflow.com/questions/73021599/how-to-enable-cgroup-v2-in-wsl2), what seems to make docker crap out above errors is the 'unified' mount point. |
Per the SO answer, you can add:
to your .wslconfig |
downgrading wsl to 1.1.3.0 worked for me. This does not effect the distro you have installed. open powershell as admin
then restart your mashine |
Same procedure works fine to reinstall 1.1.6, and with @nanobyt3 solution Docker works. So for those like me who needs the GUI layer on Windows 10, that path fixes the issue for me. |
@rlSimonLi use |
I just performed the following steps, and it appears that the error has disappeared. FYI.
After logging back into WSL, I found that the systemctl command could be used properly and the error had disappeared. At the moment, my Docker seems to be running well. This is my WSL version info:
|
Thank you lindowx it works!!! How comes that Microsoft caused all this ? |
@lindowx Thank you!!! Start docker (via systemctl): docker.service. I have set docker to start when wsl starts. I don't get these error messages anymore, so I think I've fixed this problem. |
I have the same problem from WSL. ` mount: /sys/fs/cgroup/cpuset: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error. ` |
This worked for me |
Thanks a lot @lindowx your solution worked for me! |
This issue was reported with systemd disabled, and running
so there's no |
Yep! I had the same problem running on Ubuntu 20.04.5 LTS and this solved it for me. Now I can run |
after run this cmd, i could run hello-world, but when i run an container with gpu, it fail, was it called by the same reason?
|
@dora-lemon you're running a container inside a container and |
This fixed it for me! |
I also had to enable hyper-v on Windows 11 as suggested in this article. Following the directions in this stack overflow question, I got the following config to work without the errors. Note: Upgrading the version of WSL to 1.2.0 did not fix the error. PS C:\Users\xxxxx> wsl --version
WSL version: 1.1.6.0
Kernel version: 5.15.90.1
WSLg version: 1.0.50
MSRDC version: 1.2.3770
Direct3D version: 1.608.2-61064218
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.22621.1485
PS C:\Users\xxxxx>
PS C:\Users\xxxxx> cat .\.wslconfig
[wsl2]
kernelCommandLine=cgroup_enable=memory systemd.unified_cgroup_hierarchy=0
kernelCommandLine = cgroup_no_v1=all
|
Being the impatient person I am, I ended up doing a full wipe, but your downgrade method efficiently worked. |
upgrade from WSL v1.1.6.0 => v1.2.0.0 has fixed this issue for me. |
|
Same here. Thanks! |
Updating WSL to version Thanks to WSL developers. |
wsl --shutdown WSL 版本: 1.2.0.0 Docker.Engines.WSL2.WSL2ErrorFoundInLogsException: Error found in logs indicating startup will most likely fail: Error creating 000-metadata: exit status 1 |
This fixed it for me. |
I run
|
Windows Version
Microsoft Windows [版本 10.0.22621.1485]
WSL Version
1.1.6.0
Are you using WSL 1 or WSL 2?
Kernel Version
5.15.90.1
Distro Version
Ubuntu 20.04
Other Software
Docker
Repro Steps
Expected Behavior
cgroup mount successful
Actual Behavior
wsl: .wslconfig 条目 'wsl2.swap' 的内存字符串 '0GB' 无效
mount: /sys/fs/cgroup/cpuset: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/cpu: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/cpuacct: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/blkio: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/memory: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/devices: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/freezer: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/net_cls: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/perf_event: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/net_prio: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/hugetlb: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/pids: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/rdma: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
mount: /sys/fs/cgroup/misc: wrong fs type, bad option, bad superblock on cgroup, missing codepage or helper program, or other error.
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: