Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android emulator Failed to create Vulkan instance

When creating new Android emulator in Ubuntu shows following error, does this affect my vulkan game development?

queryCoreProfileSupport: swap interval not found
emulator: ERROR: VkCommonOperations.cpp:496: Failed to create Vulkan instance.
emulator: WARNING: Ignoring invalid http proxy: Bad format: invalid port number (must be decimal)

My AVD device specification are added below.

enter image description here

like image 808
Ebin Joy Avatar asked Sep 23 '19 09:09

Ebin Joy


People also ask

How do I fix Android Emulator not working?

If the Android Emulator does not start properly, this problem is often caused by problems with HAXM. HAXM issues are often the result of conflicts with other virtualization technologies, incorrect settings, or an out-of-date HAXM driver. Try reinstalling the HAXM driver, using the steps detailed in Installing HAXM.

How do I open an emulator in separate windows?

Run the Android Emulator directly in Android Studio To run the emulator in a separate window instead go to File > Settings > Tools > Emulator (Android Studio > Preferences > Tools > Emulator on macOS) and deselect Launch in a tool window.

What to do when emulator is not working?

If the emulator fails to launch due to the error vulkan-1. dll cannot be found , you probably need to update the emulator. To update the emulator in Android Studio, go to Tools > SDK Manager and install the latest stable version of Android platform.


Video Answer


2 Answers

Your os seems ubuntu, try installing the graphic driver as below them restart the computer.

sudo ubuntu-drivers autoinstall
like image 167
aiueoH Avatar answered Sep 18 '22 05:09

aiueoH


Regarding

emulator: ERROR: VkCommonOperations.cpp:496: Failed to create Vulkan instance.

Upon fresh installation of Ubuntu, you're given the option to download and run proprietary drivers. There seems to be some compatibility issues with Android Studio Emulators running API 29, and these drivers.

Until the open source drivers (or Android Studio) fixes this, your only option is to run that proprietary code.

:-(


If you still want to, you can open up your Application Tray, then select Software & Updates. Navigate to the Additional Drivers tab, select the latest version of the proprietary drivers, then Apply Changes.

While it's doing its thing, a menu will appear where you'll set a password if you have UEFI Secure Boot. Set the password and let it finish applying changes.

When it's done, reboot your machine.

You'll be prompted during the boot process to Press any key to perform MOK management

Select the Enroll Mok Key option, then Continue, then Reboot.

You're done.

If you ever want to go back, just go back into Software & Updates and elect the open source drivers option.

like image 21
05nelsonm Avatar answered Sep 19 '22 05:09

05nelsonm