Emulator error: This AVD's configuration is missing a kernel file
Asked Answered
D

23

188

This problem was discovered when I tried to run the Android emulator in Eclipse. Can't figure out what happened. I searched online for the solution, but it seemed to be vague and I don't understand clearly. I was following the steps to install the AVD according to the sites and I can't figure out what I missed. Please explain it to me in steps to follow.

Discriminatory answered 15/3, 2012 at 0:56 Comment(4)
same problem: https://mcmap.net/q/57485/-scala-android-newbie - create a new AVDAdonic
On a mac still could not start it; using a repair on the AVD worked for me https://mcmap.net/q/57485/-scala-android-newbieSpadiceous
restarting Eclipse after installing the ARM image and then creating a new AVD worked for me.Fimbria
May be this link may help: developer.android.com/tools/help/avd-manager.htmlDetrital
B
258

The "ARM EABI v7a System Image" must be available. Install it via the Android SDK manager: Android SDK manager

Another hint (see here) - with

  • Android SDK Tools rev 17 or higher
  • Android 4.0.3 (API Level 15)
  • using SDK rev 3 and System Image rev 2 (or higher)

you are able to turn on GPU emulation to get a faster emulator: enter image description here

Note : As per you786 comment if you have previously created emulator then you need to recreate it, otherwise this will not work.

Alternative 1
Intel provides the "Intel hardware accelerated execution manager", which is a VM based emulator for executing X86 images and which is also served by the Android SDK Manager. See a tutorial for the Intel emulator here: HAXM Speeds Up the Android Emulator. Roman Nurik posts here that the Intel emulator with Android 4.3 is "blazing fast".

Alternative 2
In the comments of the post above you can find a reference to Genymotion which claims to be the "fastest Android emulator for app testing and presentation". Genymotion runs on VirtualBox. See also their site on Google+, this post from Cyril Mottier and this guide on reddit.

Alternative 3
In XDA-Forums I read about MEmu - Most Powerful Android Emulator for PC, Better Than Bluestacks. You can find the emulator here. This brings me to ...

Alternative 4
... this XDA-Forum entry: How to use THE FAST! BlueStack as your alternate Android development emulator. You can find the emulator here.

Bypath answered 11/4, 2012 at 7:32 Comment(8)
Unfortunately crashing on certain ATI cards when GPU emulation is turned on - looking forward to an updated emulator.Bypath
I found that I had to delete the emulator and recreate it after installing to solve this problem.Klaraklarika
@Klaraklarika yes it is important to recreate itDecalcify
I have done all possible way but its still there while launching simulatorKeepsake
@Klaraklarika how did you delete the emulator?Tandi
"ARM EABI v7a System Image" option is not available under API10 (Gingerbread 2.3.3) in SDK Manager. What should I do?Portecochere
agree to you786 and breceivemail, but I found that if still you have an issue related to 'kernel not found' then follow the answer of CKP78! that worked for me ...Injury
When you create a virtual device using AVD then you choose a system image (API version) which have to be downloaded anyway before you can create any device.Arius
P
22

Another reason you can get this error is that Eclipse can't find the correct file.

Check out where Eclipse is looking for your SDK files. You can do this on the command line. Below is an example for the windows command prompt for an avd I created and named 'SonyTabletS':

c:\Program Files (x86)\Android\android-sdk\tools> emulator @SonyTabletS -verbose

The first line returned shows where eclipse is looking for the SDK files and will look something like:

emulator: found ANDROID_SDK_ROOT: C:\Program Files (x86)\Android\android-sdk

Make sure that location is correct.

In my case, ANDROID_SDK_ROOT was initially set incorrectly to my home directory. This is because I set it that way by blindly following the Sony Tablet S SDK install instructions and adding an ANDROID_SDK_ROOT environment variable with the incorrect path.

Pricefixing answered 27/5, 2012 at 16:1 Comment(4)
In my case, Android\android-studio\sdk has been taken over ANDROID_SDK_ROOT location while I'm running emulator from Android\android-sdk folder. Once it correctly points to Android\android-sdk, it works.Berlauda
This was it for me. My build environment uses one ANDROID_SDK_ROOT that I can't easily update. The fix was to launch a clean command prompt and set ANDROID_SDK_ROOT to the right one and launch the sdk manager from there.Josephson
Double check that you don't accidentally have two copies of the SDK installed. If you're like me, you were installing the "ARM EABI v7a System Image" in one copy but the AVD was trying to find it in the other copy. I removed one of my copies of the SDK and then my emulator started right up.Bouncer
In my case, I have my SDK folder pointing to the correct dir.Faxan
M
22

My story, Eclipse wanted a file called "kernel-ranchu" in the system image folder ( /path/to/android-sdk-macosx/system-images/android-25/google_apis/arm64-v8a ).

emulator: ERROR: This AVD's configuration is missing a kernel file! Please ensure the file "kernel-ranchu" is in the same location as your system image.

emulator: ERROR: ANDROID_SDK_ROOT is undefined

In that system image folder there was a file called "kernel-qemu". I just renamed it as "kernel-ranchu" and it worked...

Milford answered 2/5, 2017 at 9:37 Comment(1)
In my case it was the other way aroundCretan
E
15

I had the same problem. In my case it turned out I had installed another version of the sdk alongside the version provided by Android Studio. Changing my ANDROID_SDK_ROOT environment variable to the original value fixed it for me.

Everyway answered 13/5, 2014 at 7:40 Comment(2)
It is important to note this is an equally valid answer as the top answer in the case where the SDK was previously installed before Android Studio. The bug is that Android Studio should notice that ANDROID_SDK_ROOT is already set to an alternate location and warn the user during install.Diffractive
Core is correct. I switched from Eclipse to Android Studio today and this is what fixed the issue for me.Halmahera
A
13

Here's my story. Under 'Actions' on the AVD manager, I viewed the details for the AVD which wasn't working. Scrolling down, I found the line:

image.sysdir.1: add-ons\addon-google_apis-google-16\images\armeabi-v7a\

I then navigated to this file at:

C:\Users\XXXX\AppData\Local\Android\sdk\add-ons\addon-google_apis-google-16\images\armeabi-v7a

I found there was no kernel file. However, I did find a kernel file at:

C:\Users\XXXX\AppData\Local\Android\sdk\system-images\android-16\default\armeabi-v7a

So I copied it and pasted back into:

C:\Users\XXXX\AppData\Local\Android\sdk\add-ons\addon-google_apis-google-16\images\armeabi-v7a

The AVD then worked.

Adolescence answered 21/6, 2016 at 8:56 Comment(1)
Thanks, this solved it! I think this has to be a bug or sth because it is a very strange behaviorCircumvallate
H
7

Open AVD Manager in Administrator mode Select VM and click edit, click OK Start VM.

Editor's note: By administrator mode, he meant Right-click > Run as administrator on windows platforms .

Heliozoan answered 15/2, 2014 at 10:2 Comment(2)
What/where is 'Administrator mode'?Germinative
Can't find VM, for Mac OSHarmonia
U
4

If you know the kernel file is installed on your machine, then problem is getting emulator.exe to find it.

My fix was based on the post by user2789389. I could launch the AVD from the AVD Manager, but not from the command line. So, using AVD Manager, I selected the avd I wanted to run and clicked "Details". That showed me the path to the avd definition file. Within a folder of the same name, next to this .avd file, I found a config.ini file. In the ini, I found the following line:

image.sysdir.1=system-images\android-19\default\armeabi-v7a\

I looked in the folder C:\Users\XXXX\android-sdks\system-images\android-19, and found that the image.sysdir.1 path was invalid. I had to remove the "default" sub folder, thus changing it to the following:

image.sysdir.1=system-images\android-19\armeabi-v7a\

I saved the ini and tried again to launch the AVD. That fixed the problem!

Unconventionality answered 19/9, 2014 at 14:43 Comment(4)
This did not fix it. On my case I have the sytem image in the default subfolder.Faxan
You don't have to down vote me because you have a different problem! That doesn't make my answer wrong.Unconventionality
Did you down vote every other post here too, because they didn't solve your issue?Unconventionality
This fixed the problem for me, I'm running in Mac and the path was pointing to image.sysdir.1=add-ons/addon-google_apis-google-16/images/armeabi-v7a, changing to system-images/android-16/default/armeabi-v7a solved the issueApulia
H
3

Make sure that you also have configured properly an emulated device. Android Studio may come with one that shows up in the list of emulated devices but that is not set to work with the SDK version you are using.

Try creating a new emulated device in the AVD Manager (Tools->Android>AVD Manager) and selecting that as the target.

Hilariohilarious answered 8/7, 2014 at 8:52 Comment(1)
Trying to go down this path let me know that HAXM wasn't actually installed, even though it showed it was. I was prompted to install Intel HAXM.Suprarenal
M
3

See my answer for the Android Studio environment, Mac and “PANIC: Missing emulator engine program for 'arm' CPU.”.

To solve this problem, you need to specify the -kernel path manually. i.e.

$ ~/Library/Android/sdk/emulator/emulator  @Galaxy_Nexus_Jelly_Bean_API_16 -kernel ~/Library/Android/sdk/system-images/android-16/default/armeabi-v7a/kernel-qemu

Remember to change the emulator name Galaxy_Nexus_Jelly_Bean_API_16 to your own emulator name.

Below command is to check the emulators available for command line.

$ ~/Library/Android/sdk/emulator/emulator -list-avds

And also, ensure that your emulator path is correct, i.e. the one located at ~/Library/Android/sdk/emulator/.

Manganese answered 4/9, 2018 at 8:50 Comment(0)
F
3

If you are getting this error while trying to create an emulator for Android 11 or Android 10+ (API 30), make sure that you update emulator to the latest. You can do this from Tools -> SDK Manager -> SDK Tools

enter image description here

Fremantle answered 24/9, 2020 at 15:26 Comment(1)
This was all I needed to do! Thanks, Kind Sir!Modigliani
S
2

I installed Android SDK manager and Android SDK yestoday, and I get this error too when I tried to run the Android emulator immediately. But, right now this error disappear, I think restarting your system when the SDK has installed may solve this problem.

Skid answered 10/4, 2013 at 4:0 Comment(0)
D
2

A singular intelligent thought occurred to me after a long day of repair/rebuild/upgrades of the SDK/NDK & JDK. The environment vars need examined, as the fix for my AVD 'GalaxyS3' missing kernel file was to expand the system-images reference to absolute.

image.sysdir.1=C:\Android\sdk\system-images\android-19\armeabi-v7a\

Adding the C:\....sdk\ to the image.sysdir.1= entry in the 'workspace'.android\avd\GalaxyS3.avd\config.ini file solved the problem (for now).

Delarosa answered 23/11, 2013 at 9:18 Comment(0)
H
2

I updated my android SDK to the latest version (API 19). When I tried to run the emulator with phonegap 3, the build was successful but it ran the same issue.

In the AVD manager there was an existent device, nevertheless, its parameters were all unknown. Surely this occurs because I uninstalled the old sdk version (API 17) that returns a second error while attempting to remove the device. With the message: "device is already running"

To solve the issue, I went to the AVD's location in ~/.android/avd/ and removed manually the device directory.avd and device.ini file. Finally, in the the device manager I created a new AVD provided by the newest API.

This allowed phonegap to build and run the emulator succesfully

I hope this helps

Good day

Hexapody answered 9/4, 2014 at 20:3 Comment(0)
A
2

Following the accepted answer by ChrLipp using Android Studio 1.2.2 in Ubuntu 14.04:

  • Install "ARM EABI v7a System Image" package from Android SDK manager.
  • Delete the non functional Virtual Device.
  • Add a new device with Application Binary Interface(ABI) as armeabi-v7a.
  • Boot into the new device.

This worked for me. Try rebooting your system if it is not working for you.

Avarice answered 15/7, 2015 at 13:35 Comment(0)
B
2

In my own case, I had multiple errors most of which were about mis-configured ANDROID_SDK_ROOT, at the end of the day, one thing seemed to fix the whole thing.

Follow the following process:

After Creating the A new Emulator Device on AVD, go to the Actions menu and click on the arrow pointing downwards as shown below.

enter image description here

Click on Show on Disk

Edit Config.ini

Look for image.sysdir.1

it should have a value like this : image.sysdir.1=system-images\android-28\google_apis_playstore\x86\

Your own value might be different

Now, fix in the path of the Android SDK to make a complete path.

image.sysdir.1=**C:\androidsdk\**system-images\android-28\google_apis_playstore\x86\

If you noticed, the android sdk path shown above is different from the normal default android sdk, I had to move it to C:/androidsdk to avoid NDK issues as my main USER HOME on my PC has whitespaces which NDK might not support.

NOTE: Moving the SDK directory away from its default directory is usually the cause of these errors AVD emulator gives, most especially as regarding broken and misconfigured path. The fix I provided above is a quick fix, you may have to do that each time you create a new device on AVD Emulator.

This fix should also work when working on CMD with cordova .

Boreas answered 11/8, 2018 at 6:9 Comment(0)
B
1

I tried what ChrLipp suggested, but that wasn't the problem, as the image was already installed. What I did was run:

android avd

to start the emulator manually. Then I stopped the emulator, and form that point on the

cca emulate android

app started working, without the "missing a kernel file" error.

Bemoan answered 22/9, 2014 at 20:42 Comment(0)
N
1

I fixed this problem just adding the Enviroment variable ANDROID_SDK_ROOT, in my case this was located at C:\Users\fera\AppData\Local\Android\sdk

Namesake answered 6/11, 2015 at 4:51 Comment(0)
M
1

There was a file called kernel-ranchu , I renamed it to kernel-qemu.

This solved my problem. Thank you.

Martini answered 31/10, 2020 at 8:59 Comment(0)
B
1

I finally managed to solve this issue - download an older version of Android Studio: https://developer.android.com/studio/archive (I chose this one: Android Studio 2.3.2 May 11, 2017)

Install full bundle with Internet disconnected: Windows IDE bundle with SDK (64-bit): android-studio-bundle-162.3934792-windows.exe (2.0 GB)

Re-connect to Internet then download the required Android platform version without updating any other modules.

Baram answered 11/4, 2023 at 6:17 Comment(0)
F
0

Just wanted to share my experience on this problem. Consulting each of the answers here, it didn't match my situation. Having a system image for Android API 22 causes this error and the weird thing is that all of the environment variables pointing to the correct directories. It doesn't make sense.

@BuvinJ answer had shed some light into the problem. I did check on the path describe on his answer and yes my copy of system image resides under the subfolder default when I look on the user directory (on Windows).

The weird thing is, there is also an android-sdk folder in the ANDROID_SDK_ROOT so I thought maybe Eclipse is looking there. Digging through the subfolders I figured out that the directory looks like this:

android-sdk-windows\system-images\android-22\google_apis\armeabi-v7a

This directory resides on the ANDROID_SDK_ROOT. There is also another one residing at the user directory user/XXXX/android-sdk/.

Eclipse is expecting it here:

android-sdk-windows\system-images\android-22\default\armeabi-v7a

Just changed the directory as such and it works now.

Faxan answered 5/8, 2015 at 3:15 Comment(0)
M
0

Update the following commands in command prompt in windows:

  1. android update sdk --no-ui --all
    It update your SDK packages and it takes 3 minutes.
  2. android update sdk --no-ui --filter platform-tools,tools
    It updates the platform tools and its packages.
  3. android update sdk --no-ui --all --filter extra-android-m2repository
    Those who are working with maven project update this to support with latest support design library which will include extra maven android maven Repository.
  1. In the command prompt it asks you for Y/N. Click on the Y then it proceeds with the installation.
  2. It updates all Kernel-qemu files and qt5.dll commands. so that the Emulator works fine without any issues.
Mila answered 5/1, 2020 at 2:40 Comment(0)
C
-1

For me Updating the SDK Tools fixed the errors.

Screenshot of the errors and update progress

Cacique answered 5/1, 2019 at 10:55 Comment(0)
S
-1

I solved this by updating SDK Tools and Platform-tools in the Android SDK Manager to newest version.

Sauerkraut answered 17/1, 2019 at 14:32 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.