I try to screen into docker desktop vm using screen ~/Library/Containers/com.docker.docker/Data/vms/0/tty
, which work previously. But today is said Cannot execute "/Users/myusername/Library/Containers/com.docker.docker/Data/vms/0/tty": Operation not permitted
. I search and found solution saying setting security and privacy of system preference which I did follow (below image). But still I got the errors, can anyone help?
Asked
Active
Viewed 3,691 times
3

Vadim Kotov
- 8,084
- 8
- 48
- 62

HKIT
- 628
- 1
- 8
- 19
-
On Mac os ventura version 13.0.1 and docker app version 4.14.0 (91374), the screen command just exits after a few seconds because the file ~/Library/Containers/com.docker.docker/Data/vms/0/tty doesn't exist. – user674669 Jan 04 '23 at 13:08
3 Answers
3
While I don't understand the reason for this issue, I experienced the same, and the following helped for me:
- Make the tty file readable:
chmod 400 ~/Library/Containers/com.docker.docker/Data/vms/0/tty
- Do not try to execute that file, but read its contents:
screen $(cat ~/Library/Containers/com.docker.docker/Data/vms/0/tty)
Not the most beautiful solution, but works form me.

Bastian Friedrich
- 31
- 2
-
1Thank you. I found another solution which is similar: screen /dev/ttys000, the /dev/ttys000 is the place the tty file points to (open tty as text file). – HKIT Aug 13 '20 at 10:34
-
On Mac os ventura version 13.0.1 and docker app version 4.14.0 (91374), the screen command just exits after a few seconds because the file ~/Library/Containers/com.docker.docker/Data/vms/0/tty doesn't exist. – user674669 Jan 04 '23 at 13:01
0
It seems the problem in recent Docker versions(Github issue). I tried many ways to workaround before downgrading the Docker. Finally, Docker version stable 2.3.0.2(45183) work for me

Dharman
- 30,962
- 25
- 85
- 135

Huy Hóm Hỉnh
- 597
- 7
- 18
0
Try:
$ docker run -it --rm --privileged --pid=host busybox nsenter -t1 -m -u -i -n
Related issue: How to access the VM created by docker's HyperKit?

user674669
- 10,681
- 15
- 72
- 105