-
Notifications
You must be signed in to change notification settings - Fork 28.8k
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
VS Code 1.79.0 use root user can not open with cmd --no-sandbox --user-data-dir #184687
Comments
Same issue after updating to 1.79.0 on Windows 10 (19045.2965) and trying to launch Code as admin with Logs[main 2023-06-09T08:46:43.113Z] IPC Object URL: Registered new channel vscode:aba3ed2f-13a2-43fe-8cd1-7c38f6cb798b. [main 2023-06-09T08:46:43.113Z] window#validateWindowState: validating window state on 2 display(s) { mode: 0, x: 2381, y: 0, width: 1459, height: 846 } [main 2023-06-09T08:46:43.113Z] window#validateWindowState: multi-monitor working area { x: 1920, y: 0, width: 1920, height: 1040 } [main 2023-06-09T08:46:43.113Z] window#ctor: using window state { mode: 0, x: 2381, y: 0, width: 1459, height: 846 } [main 2023-06-09T08:46:43.158Z] window#load: attempt to load window (id: 1) [main 2023-06-09T08:46:43.172Z] windowsManager#open used window count 1 (workspacesToOpen: 0, foldersToOpen: 0, emptyToRestore: 1, emptyToOpen: 0) [main 2023-06-09T08:46:43.172Z] lifecycle (main): phase changed (value: 3) [main 2023-06-09T08:46:43.177Z] resolveShellEnv(): skipped (Windows) [main 2023-06-09T08:46:43.177Z] update#setState idle Renderer process launch-failed - see https://www.electronjs.org/docs/tutorial/application-debugging for potential debugging information. [main 2023-06-09T08:46:43.194Z] CodeWindow: renderer process gone (reason: launch-failed, code: 18) [33572:0609/104643.231:INFO:electron_api_web_frame_main.cc(235)] Attempt to setup WebFrameMain connection while render frame is disposed [main 2023-06-09T08:46:43.227Z] [File Watcher (node.js)] Started watching: 'c:\Users\grinenkoa\AppData\Roaming\Code\User' Renderer process launch-failed - see https://www.electronjs.org/docs/tutorial/application-debugging for potential debugging information. [main 2023-06-09T08:46:43.230Z] CodeWindow: renderer process gone (reason: launch-failed, code: 18) |
@sjwyz can you start with @Arko109 thanks for the logs, exit code 18 is generic process launch error from the chromium sandbox layer https://source.chromium.org/chromium/chromium/src/+/refs/heads/main:sandbox/win/src/target_process.cc;l=181-191 so looks like sandbox did not get disabled in your case. To which executable did you pass the flags ? Maybe a screen recording would help. |
@deepak1556 use arguments |
@deepak1556 And my Rockylinux9.2 is installed on Windows version vmware Workstation 17 |
@deepak1556 I have a shortcut that points to Videos2023-06-09-131537.mp42023-06-09-133359.mp4 |
Same issue on Kubuntu 22.04.2. Terminal logs with '--verbose' tells that VSCode ignoring --no-sandbox flag (startup args contains 'no-sandbox': false), then spamming with "Running under root without --no-sandbox flag is not supported" |
Microsoft Office developers are experiencing this issue as well. Things tried: 1 - 2 - I tried creating a dump, but it only creates a dat file.
3 - I have recorded time travel traces of the different processes.
|
I have some feeling that update has broke argument parsing/saving on no-sandbox flag because I have this output: Verbose output`# code --user-data-dir="/root/.vscode" --no-sandbox --verbose [102303:0610/020244.034319:WARNING:bluez_dbus_manager.cc(247)] Floss manager not present, cannot set Floss enable/disable. [main 2023-06-09T23:02:44.176Z] [File Watcher (node.js)] Request to start watching: /root/.vscode/User (excludes: , includes: ),/root/.vscode/User/settings.json (excludes: , includes: ) [0610/020244.198923:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [main 2023-06-09T23:02:44.201Z] Starting VS Code [main 2023-06-09T23:02:44.201Z] from: /usr/share/code/resources/app [main 2023-06-09T23:02:44.202Z] args: { _: [], diff: false, merge: false, add: false, goto: false, 'new-window': false, 'reuse-window': false, wait: false, 'user-data-dir': '/root/.vscode', help: false, 'list-extensions': false, 'show-versions': false, 'pre-release': false, version: false, verbose: true, status: false, 'prof-startup': false, 'no-cached-data': false, 'prof-v8-extensions': false, 'disable-extensions': false, 'disable-gpu': false, 'ms-enable-electron-run-as-node': false, telemetry: false, debugRenderer: false, 'enable-smoke-test-driver': false, logExtensionHostCommunication: false, 'skip-release-notes': false, 'skip-welcome': false, 'disable-telemetry': false, 'disable-updates': false, 'disable-keytar': false, 'disable-workspace-trust': false, 'disable-crash-reporter': false, 'crash-reporter-id': 'd3f810e8-d4bf-4c6c-b47c-cef319bf1b60', 'skip-add-to-recently-opened': false, 'unity-launch': false, 'open-url': false, 'file-write': false, 'file-chmod': false, force: false, 'do-not-sync': false, trace: false, 'force-user-env': false, 'force-disable-user-env': false, 'open-devtools': false, 'disable-gpu-sandbox': false, '__enable-file-policy': false, 'enable-coi': false, 'no-proxy-server': false, 'no-sandbox': false, nolazy: false, 'force-renderer-accessibility': false, 'ignore-certificate-errors': false, 'allow-insecure-localhost': false, 'disable-dev-shm-usage': false, 'profile-temp': false, logsPath: '/root/.vscode/logs/20230610T020244' } [main 2023-06-09T23:02:44.206Z] Resolving machine identifier... [main 2023-06-09T23:02:44.206Z] Resolved machine identifier: 9ca044ac56a200b25f97a24709fdad525caa02c9d29e3134ef3c2c0e8e50f74f [main 2023-06-09T23:02:44.206Z] Main->SharedProcess#connect [main 2023-06-09T23:02:44.211Z] [File Watcher (node.js)] Started watching: '/root/.vscode/User' [main 2023-06-09T23:02:44.213Z] [File Watcher (node.js)] Started watching: '/root/.vscode/User/settings.json' [main 2023-06-09T23:02:44.216Z] StorageMainService: creating application storage [main 2023-06-09T23:02:44.225Z] ElectronURLListener: waiting for window to be ready to handle URLs... [main 2023-06-09T23:02:44.225Z] lifecycle (main): phase changed (value: 2) [main 2023-06-09T23:02:44.226Z] windowsManager#open [102333:0610/020244.226525:WARNING:sandbox_linux.cc(380)] InitializeSandbox() called with multiple threads in process gpu-process. [main 2023-06-09T23:02:44.226Z] windowsManager#open pathsToOpen [ { backupPath: '/root/.vscode/Backups/1686313915326', remoteAuthority: undefined } ] [main 2023-06-09T23:02:44.227Z] windowsManager#doOpenEmpty { restore: true, remoteAuthority: undefined, filesToOpen: undefined, forceNewWindow: true } [main 2023-06-09T23:02:44.229Z] IPC Object URL: Registered new channel vscode:254a97f4-1783-438f-b576-add0d3e00854. [main 2023-06-09T23:02:44.230Z] window#validateWindowState: validating window state on 1 display(s) { mode: 0, x: 0, y: 29, width: 1920, height: 1011 } [main 2023-06-09T23:02:44.230Z] window#validateWindowState: 1 monitor working area { x: 0, y: 0, width: 1920, height: 1040 } [main 2023-06-09T23:02:44.231Z] window#ctor: using window state { mode: 0, x: 0, y: 29, width: 1920, height: 1011 } [main 2023-06-09T23:02:44.320Z] window#load: attempt to load window (id: 1) [main 2023-06-09T23:02:44.337Z] windowsManager#open used window count 1 (workspacesToOpen: 0, foldersToOpen: 0, emptyToRestore: 1, emptyToOpen: 0) [main 2023-06-09T23:02:44.337Z] lifecycle (main): phase changed (value: 3) [main 2023-06-09T23:02:44.337Z] resolveShellEnv(): skipped (VSCODE_CLI is set) [main 2023-06-09T23:02:44.338Z] update#setState idle [102303:0610/020244.444472:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020244.486842:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020244.673278:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020244.707520:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020244.878822:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020244.909962:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020245.105310:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020245.139476:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020245.311264:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020245.345518:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020245.528944:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020245.560666:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020245.750638:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020245.797133:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020245.914979:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020245.938484:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020246.108599:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020246.148474:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020246.182080:ERROR:service_worker_storage.cc(1933)] Failed to delete the database: Database IO error [102303:0610/020246.279736:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020246.316049:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180. [102303:0610/020246.507002:ERROR:network_service_instance_impl.cc(521)] Network service crashed, restarting service. [0610/020246.552562:FATAL:electron_main_delegate.cc(304)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180.`Look at no-sandbox element in args dict, it has false value, but --no-sandbox flag presented in run command. Also there are a lot of FATAL messages on not presented --no-sandbox flag |
This seems to break quite a few people's CI's, as in the referenced issue: microsoft/vscode-test#221 |
Seeing the same thing on Windows Server 2019 as @Arko109 |
Getting the same issue when using |
My headless CI tests works with 1.78.2 , but as soon as I use .79, it starts crashing continuously with below messages repeated.
|
Nope not possible currently, it is a limitation from the chromium runtime https://bugs.chromium.org/p/chromium/issues/detail?id=740132 and I am tracking it in #122951. Edge de-elevates the application under these scenarios, so it might be potential fix for this issue. |
@deepak1556 |
@deepak1556 |
@sjwyz thanks for confirming, you can ignore the |
@reukiodo it's in 1.79.2 |
Hi, I just get a blank dialog as shown in the attachment below. I am also attaching my logs. Any help would be extremely grateful. |
@Satya-Sidhu are you able to launch the application without |
As a non-root user I can launch it without sudo. But cannot launch it with sudo as a non-root user. Also cannot launch it if I switch over to root account. |
As you can see below, without sudo everything seems to startup successfully. |
@Satya-Sidhu thanks for confirming, in your previous comment #184687 (comment) I missed that you are not launching with |
Hi @deepak1556, this Thank you very much for your help. |
@deepak1556 Is there a way to persist |
@tiagomacarios we will provide a setting to persist this option with |
@tiagomacarios In linux I can use 'alias' command like |
What is the equivalent of |
Type: Bug
Steps to Reproduce:
Jun 9 15:27:06 R9 systemd[1]: systemd-coredump@610-6281-0.service: Deactivated successfully.
Jun 9 15:27:06 R9 systemd[1]: Started Process Core Dump (PID 6287/UID 0).
Jun 9 15:27:06 R9 systemd-coredump[6288]: Resource limits disable core dumping for process 6286 (code).
Jun 9 15:27:06 R9 systemd-coredump[6288]: Process 6286 (code) of user 0 dumped core.
Jun 9 15:27:06 R9 systemd[1]: systemd-coredump@611-6287-0.service: Deactivated successfully.
Jun 9 15:27:06 R9 systemd[1]: Started Process Core Dump (PID 6293/UID 0).
Jun 9 15:27:06 R9 systemd-coredump[6294]: Resource limits disable core dumping for process 6292 (code).
Jun 9 15:27:06 R9 systemd-coredump[6294]: Process 6292 (code) of user 0 dumped core.
Jun 9 15:27:06 R9 systemd[1]: systemd-coredump@612-6293-0.service: Deactivated successfully.
Jun 9 15:27:06 R9 systemd[1]: Started Process Core Dump (PID 6299/UID 0).
Jun 9 15:27:06 R9 systemd-coredump[6300]: Resource limits disable core dumping for process 6298 (code).
Jun 9 15:27:06 R9 systemd-coredump[6300]: Process 6298 (code) of user 0 dumped core.
Jun 9 15:27:06 R9 systemd[1]: systemd-coredump@613-6299-0.service: Deactivated successfully.
Jun 9 15:27:06 R9 systemd[1]: Started Process Core Dump (PID 6305/UID 0).
Jun 9 15:27:06 R9 systemd-coredump[6306]: Resource limits disable core dumping for process 6304 (code).
Jun 9 15:27:06 R9 systemd-coredump[6306]: Process 6304 (code) of user 0 dumped core.
Jun 9 15:27:06 R9 systemd[1]: systemd-coredump@614-6305-0.service: Deactivated successfully.
Jun 9 15:27:06 R9 systemd[1]: Started Process Core Dump (PID 6311/UID 0).
Jun 9 15:27:06 R9 systemd-coredump[6313]: Resource limits disable core dumping for process 6310 (code).
Jun 9 15:27:06 R9 systemd-coredump[6313]: Process 6310 (code) of user 0 dumped core.
Jun 9 15:27:06 R9 systemd[1]: systemd-coredump@615-6311-0.service: Deactivated successfully.
Jun 9 15:27:32 R9 systemd[1]: virtqemud.service: Deactivated successfully.
Jun 9 15:27:44 R9 systemd[1]: Crash recovery kernel arming was skipped because of an unmet condition check (ConditionKernelCommandLine=crashkernel).
Jun 9 15:27:49 R9 kernel: show_signal: 30 callbacks suppressed
Jun 9 15:27:49 R9 kernel: traps: code[6431] trap int3 ip:56500835a0de sp:7ffee17641e0 error:0 in code[565005131000+70a8000]
Jun 9 15:27:49 R9 systemd[1]: Started Process Core Dump (PID 6432/UID 0).
Jun 9 15:27:49 R9 systemd-coredump[6433]: Resource limits disable core dumping for process 6431 (code).
Jun 9 15:27:49 R9 systemd-coredump[6433]: Process 6431 (code) of user 0 dumped core.
Jun 9 15:27:49 R9 systemd[1]: systemd-coredump@616-6432-0.service: Deactivated successfully.
Jun 9 15:27:49 R9 kernel: traps: code[6439] trap int3 ip:55fc8b24f0de sp:7ffdc2d3cd70 error:0 in code[55fc88026000+70a8000]
Jun 9 15:27:49 R9 systemd[1]: Started Process Core Dump (PID 6441/UID 0).
Jun 9 15:27:49 R9 systemd-coredump[6442]: Resource limits disable core dumping for process 6439 (code).
Jun 9 15:27:49 R9 systemd-coredump[6442]: Process 6439 (code) of user 0 dumped core.
Jun 9 15:27:49 R9 systemd[1]: systemd-coredump@617-6441-0.service: Deactivated successfully.
Jun 9 15:27:49 R9 kernel: traps: code[6464] trap int3 ip:564e6e8100de sp:7ffe4a79e980 error:0 in code[564e6b5e7000+70a8000]
Jun 9 15:27:49 R9 systemd[1]: Started Process Core Dump (PID 6465/UID 0).
Jun 9 15:27:49 R9 systemd-coredump[6466]: Resource limits disable core dumping for process 6464 (code).
Jun 9 15:27:49 R9 systemd-coredump[6466]: Process 6464 (code) of user 0 dumped core.
Jun 9 15:27:49 R9 systemd[1]: systemd-coredump@618-6465-0.service: Deactivated successfully.
Jun 9 15:27:49 R9 kernel: traps: code[6470] trap int3 ip:55953e5650de sp:7ffd8aa79710 error:0 in code[55953b33c000+70a8000]
Jun 9 15:27:49 R9 systemd[1]: Started Process Core Dump (PID 6471/UID 0).
Jun 9 15:27:49 R9 systemd-coredump[6472]: Resource limits disable core dumping for process 6470 (code).
Jun 9 15:27:49 R9 systemd-coredump[6472]: Process 6470 (code) of user 0 dumped core.
Jun 9 15:27:49 R9 systemd[1]: systemd-coredump@619-6471-0.service: Deactivated successfully.
Jun 9 15:27:49 R9 kernel: traps: code[6476] trap int3 ip:5641a50f00de sp:7ffc1ea51e40 error:0 in code[5641a1ec7000+70a8000]
Jun 9 15:27:49 R9 systemd[1]: Started Process Core Dump (PID 6477/UID 0).
Jun 9 15:27:49 R9 systemd-coredump[6478]: Resource limits disable core dumping for process 6476 (code).
VS Code version: Code - Insiders 1.79.0-insider (b380da4, 2023-06-07T14:26:54.152Z)
OS version: Windows_NT x64 10.0.22621
Modes:
The text was updated successfully, but these errors were encountered: