Open jonashaag opened 2 years ago
I don't really understand why it works in the first case when you got all of these tar errors. There is definitely something wrong. You could email me the full log from the Remote-SSH output channel and we could see whether that has any useful info.
Sorry for the slow response. Missed the email.
I don't really understand why the previous one works - it produced the same errors. I used to ignore tar errors but that was a long time ago... There are hundreds of errors of the same pattern that I see above
tar: vscode-server-linux-x64/node_modules: Cannot change ownership to uid 0, gid 0: Permission denied
you need to look at what user you are using to connect with ssh and what permissions it has on this remote system.
I think I figured it out, the problem is that the remote machine's ~
is on a network filesystem that has funny file permission behaviour:
$ cd
$ id
uid=0(root) gid=0(root) groups=0(root)
$ touch /tmp/test test
$ ls -l /tmp/test test
-rw-r--r-- 1 root root 0 Oct 22 12:27 /tmp/test
-rw-r--r-- 1 930960 54615 0 Oct 22 12:27 test
$ chown 0:0 /tmp/test
$ chown 0:0 test
chown: changing ownership of 'test': Permission denied
$ chown 930960:54615 /tmp/test
$ chown 930960:54615 test
Closing this issue since it looks like @jonashaag, you got it solved?
No it’s not solved. I can’t change anything about those permissions so I’m unable to use VSCode remote in a recent version.
I am not an expert, I wonder whether this is a case like this?: https://superuser.com/questions/1435437/how-to-get-around-this-error-when-untarring-an-archive-tar-cannot-change-owner
If you can reproduce the error message in the log from running tar manually, and --no-same-owner
fixes it, that would be useful info
Yes, I can reproduce with that. Here, /tmp/xxx.tar
is an archive that contains a file xxx
that has uid=gid=0, and my user also has uid=gid=0, but the filesystem automatically changes the uid and gid.
$ tar xfv /tmp/xxx.tar
xxx
tar: xxx: Cannot change ownership to uid 0, gid 0: Permission denied
tar: Exiting with failure status due to previous errors
$ tar xfv /tmp/xxx.tar --no-same-owner
xxx
Version: 1.60.1 (user setup) Commit: 83bd43bc519d15e50c4272c6cf5c1479df196a4d Date: 2021-09-10T17:07:10.714Z Electron: 13.1.8 Chrome: 91.0.4472.164 Node.js: 14.16.0 V8: 9.1.269.39-electron.0 OS: Windows_NT x64 10.0.19042
Remote OS Version: Ubuntu 20.04 Docker container
Remote Extension/Connection Type: SSH (not using Docker because it's unavailable on the Windows machine)
Steps to Reproduce:
~/.vscode-server
on the remote, reconnect, server setup doesn't work, see logs below.Happy to share the full logs privately.
v0.65.7 logs:
v0.65.8 logs: