zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
39.25k stars 2.03k forks source link

Zed not working in VirtualBox #13179

Open densyy opened 2 weeks ago

densyy commented 2 weeks ago

Check for existing issues

Describe the bug / provide steps to reproduce it

zeditor --foreground

[2024-06-17T19:15:36-03:00 ERROR gpui::platform::linux::x11::client] XIM Event Sender dropped                                
[2024-06-17T19:15:36-03:00 ERROR zed::reliability] {
  "thread": "main",
  "payload": "called `Result::unwrap()` on an `Err` value: ERROR_INCOMPATIBLE_DRIVER",
  "location_data": {
    "file": "/build/.cargo/git/checkouts/blade-b2bcd1de1cf7ab6a/bdaf8c5/blade-graphics/src/vulkan/init.rs",
    "line": 346
  },
  "backtrace": [
    "__libc_start_main"
  ],
  "app_version": "1.0.0",
  "release_channel": "Zed",
  "os_name": "Linux",
  "os_version": "1.0.0",
  "architecture": "x86_64",
  "panicked_on": 1718662536299,
  "installation_id": "10070e5d-3f21-4cb2-a18d-bde9cf2a0e62",
  "session_id": "3b02eb02-6354-4612-ac13-1bfc0f1a5e8f"
}

Environment

Running inside VirtualBox 7.0

OS: Arch Linux x86_64 Host: VirtualBox 1.2 Kernel: 6.9.4-arch1-1 CPU: Intel i7-10750H (4) @ 2.591GHz GPU: 00:02.0 VMware SVGA II Adapter Memory: 2761MiB / 5957MiB

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

No response

unkn0wncvm1 commented 2 weeks ago

Did You Install The Vulkan Drivers For VirtualBox?

densyy commented 2 weeks ago

Did You Install The Vulkan Drivers For VirtualBox?

I installed it using these commands: sudo pacman -S vulkan-icd-loader vulkan-tools

But I got this error when running: vulkaninfo

WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Received return code -9 from call to vkCreateInstance in ICD /usr/lib/amdvlk64.so. Skipping this driver.
ERROR: [Loader Message] Code 0 : terminator_CreateInstance: Found no drivers!
Cannot create Vulkan instance.
This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan.
ERROR at /usr/src/debug/vulkan-tools/Vulkan-Tools-1.3.269/vulkaninfo/./vulkaninfo.h:688:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVER
unkn0wncvm1 commented 1 week ago

Did You Install The Vulkan Drivers For VirtualBox?

I installed it using these commands: sudo pacman -S vulkan-icd-loader vulkan-tools

But I got this error when running: vulkaninfo

WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Received return code -9 from call to vkCreateInstance in ICD /usr/lib/amdvlk64.so. Skipping this driver. ERROR: [Loader Message] Code 0 : terminator_CreateInstance: Found no drivers! Cannot create Vulkan instance. This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan. ERROR at /usr/src/debug/vulkan-tools/Vulkan-Tools-1.3.269/vulkaninfo/./vulkaninfo.h:688:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVER

Did You install the virtualbox-guest-utils package?

densyy commented 1 week ago

Did You Install The Vulkan Drivers For VirtualBox?

I installed it using these commands: sudo pacman -S vulkan-icd-loader vulkan-tools But I got this error when running: vulkaninfo WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Received return code -9 from call to vkCreateInstance in ICD /usr/lib/amdvlk64.so. Skipping this driver. ERROR: [Loader Message] Code 0 : terminator_CreateInstance: Found no drivers! Cannot create Vulkan instance. This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan. ERROR at /usr/src/debug/vulkan-tools/Vulkan-Tools-1.3.269/vulkaninfo/./vulkaninfo.h:688:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVER

Did You install the virtualbox-guest-utils package?

Yes, it's installed: virtualbox-guest-utils 7.0.18-1

unkn0wncvm1 commented 1 week ago

Did You Install The Vulkan Drivers For VirtualBox?

I installed it using these commands: sudo pacman -S vulkan-icd-loader vulkan-tools But I got this error when running: vulkaninfo WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Received return code -9 from call to vkCreateInstance in ICD /usr/lib/amdvlk64.so. Skipping this driver. ERROR: [Loader Message] Code 0 : terminator_CreateInstance: Found no drivers! Cannot create Vulkan instance. This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan. ERROR at /usr/src/debug/vulkan-tools/Vulkan-Tools-1.3.269/vulkaninfo/./vulkaninfo.h:688:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVER

Did You install the virtualbox-guest-utils package?

Yes, it's installed: virtualbox-guest-utils 7.0.18-1

Is The vboxservice service loaded and running?

unkn0wncvm1 commented 1 week ago

Can You Rebuild it with RUSTFLAGS="--cfg gles"?

densyy commented 1 week ago

Did You Install The Vulkan Drivers For VirtualBox?

I installed it using these commands: sudo pacman -S vulkan-icd-loader vulkan-tools But I got this error when running: vulkaninfo WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Received return code -9 from call to vkCreateInstance in ICD /usr/lib/amdvlk64.so. Skipping this driver. ERROR: [Loader Message] Code 0 : terminator_CreateInstance: Found no drivers! Cannot create Vulkan instance. This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan. ERROR at /usr/src/debug/vulkan-tools/Vulkan-Tools-1.3.269/vulkaninfo/./vulkaninfo.h:688:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVER

Did You install the virtualbox-guest-utils package?

Yes, it's installed: virtualbox-guest-utils 7.0.18-1

Is The vboxservice service loaded and running?

vboxservice is not running. Check log error:

systemctl status vboxservice                   
× vboxservice.service - VirtualBox Guest Service
     Loaded: loaded (/usr/lib/systemd/system/vboxservice.service; enabled; preset: disabled)
     Active: failed (Result: exit-code) since Tue 2024-06-18 04:39:53 -03; 1min 1s ago
   Duration: 3ms
  Condition: start condition unmet at Tue 2024-06-18 04:40:51 -03; 3s ago
             └─ ConditionVirtualization=oracle was not met
   Main PID: 48564 (code=exited, status=1/FAILURE)
        CPU: 17ms

jun 18 04:39:53 densyy-vm systemd[1]: Starting VirtualBox Guest Service...
jun 18 04:39:53 densyy-vm systemd[1]: Started VirtualBox Guest Service.
jun 18 04:39:53 densyy-vm VBoxService[48564]: VBoxService: error: VbglR3Init failed with rc=VERR_FILE_NOT_FOUND
jun 18 04:39:53 densyy-vm systemd[1]: vboxservice.service: Main process exited, code=exited, status=1/FAILURE
jun 18 04:39:53 densyy-vm systemd[1]: vboxservice.service: Failed with result 'exit-code'.
jun 18 04:40:51 densyy-vm systemd[1]: VirtualBox Guest Service was skipped because of an unmet condition check (ConditionVirtualization=oracle).

I'm using systemd-modules-load.service, because virtualbox-host-dkms is installed for my kernel 6.9.4-arch1-1 Check log:

systemctl status systemd-modules-load.service

● systemd-modules-load.service - Load Kernel Modules
     Loaded: loaded (/usr/lib/systemd/system/systemd-modules-load.service; static)
     Active: active (exited) since Mon 2024-06-17 01:31:29 -03; 1 day 3h ago
       Docs: man:systemd-modules-load.service(8)
             man:modules-load.d(5)
   Main PID: 357 (code=exited, status=0/SUCCESS)
        CPU: 26ms

jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Inserted module 'acpi_call'
jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Inserted module 'crypto_user'
jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Module 'nvidia_uvm' is deny-listed (by kmod)
jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Failed to insert module 'tp_smapi': No such device
jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Inserted module 'vboxdrv'
jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Inserted module 'vboxnetadp'
jun 17 01:31:29 densyy-vm systemd-modules-load[357]: Inserted module 'vboxnetflt'
jun 17 01:31:29 densyy-vm systemd[1]: Finished Load Kernel Modules.
Notice: journal has been rotated since unit was started, output may be incomplete.