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

call control.Delete() occur err=cgroups: unable to remove path "/sys/fs/cgroup/devices/test" #148

Open
ycchildcoder opened this issue Mar 6, 2020 · 1 comment
Labels

Comments

@ycchildcoder
Copy link

I write a test,when I call control.Delete() , it occur error:
err=cgroups: unable to remove path "/sys/fs/cgroup/devices/test"
inside
err= unlinkat /sys/fs/cgroup/devices/test/tasks: operation not permitted
I don't know why, when i remove control.Add(cgroups.Process{Pid: 1234}), it has not error。
thanks

@AkihiroSuda
Copy link
Member

Adding os.Remove() before os.RemoveAll() solves the issue?

if err := os.RemoveAll(path); err == nil {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants