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

[9p] chown: changing ownership of 'xxx': Operation not permitted #1169

Closed
nulllpoint opened this issue Nov 16, 2022 · 2 comments
Closed

[9p] chown: changing ownership of 'xxx': Operation not permitted #1169

nulllpoint opened this issue Nov 16, 2022 · 2 comments
Labels
component/qemu/9p question Further information is requested

Comments

@nulllpoint
Copy link

nulllpoint commented Nov 16, 2022

Description

I read the issuse #231 , has it been solved now?

I use podman by lima-vm, container is mysql/mysql-server, it need chown mysql:mysql xxx, but when use -v mapping host's dir , propmpt chown: changing ownership of 'xxx': Operation not permitted
macos version: 12.6
lima version: 0.13.0
qemu version: 7.1.0
lima's yaml config:

mountType: 9p
mounts:
- location: "/Users/xxx/lima_workspace/podman"
  writable: true
  9p:
    cache: mmap

mysql docker hub:

docker hub : https://hub.docker.com/r/mysql/mysql-server
fetch cmd: docker pull mysql/mysql-server:8.0.21

I also try to use chown directly in lima-vm, neither.

[xxx@lima-test test]$ sudo groupadd test
[xxx@lima-test test]$ sudo useradd -g test test
[xxx@lima-test test]$ ll
drwxr-xr-x. 4 xxx games 128 Nov 16 08:55 mysql
drwxrwxr-x. 2 xxx games  64 Nov 16 08:48 test
[xxx@lima-test test]$ chown test:test test
chown: changing ownership of 'test': Operation not permitted
@AkihiroSuda AkihiroSuda added component/qemu/9p question Further information is requested labels Nov 16, 2022
@AkihiroSuda
Copy link
Member

9p:
# Supported security models are "passthrough", "mapped-xattr", "mapped-file" and "none".
# "mapped-xattr" and "mapped-file" are useful for persistent chown but incompatible with symlinks.
# 🟢 Builtin default: "none" (since Lima v0.13)
securityModel: null

securityModel: "mapped-xattr" enables chown, but incompatible with symlinks

@AkihiroSuda AkihiroSuda changed the title chown: changing ownership of 'xxx': Operation not permitted [9p] chown: changing ownership of 'xxx': Operation not permitted Nov 16, 2022
@nulllpoint
Copy link
Author

nulllpoint commented Nov 17, 2022

9p:
# Supported security models are "passthrough", "mapped-xattr", "mapped-file" and "none".
# "mapped-xattr" and "mapped-file" are useful for persistent chown but incompatible with symlinks.
# 🟢 Builtin default: "none" (since Lima v0.13)
securityModel: null

securityModel: "mapped-xattr" enables chown, but incompatible with symlinks

Thank you for your reply, but it still seems to be unresolved.
That is my lima.conf, pass the limactl validate

mountType: "9p"
mounts:
- location: "/Users/xxx/lima_workspace/test"
  writable: true
  9p:
    cache: "mmap"
    securityModel: "mapped-xattr"
- location: "/tmp/lima"
  writable: true

The above is useful. When I recreated lima's vm, the problem was solved,
This problem has bothered me for almost two days, hahhhh....
Great lima vm !!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/qemu/9p question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants