31

I've downloaded the latest Android x86 (android-x86-6.0_20160129.iso) from here and tried to install it to the HDD on a VM in VMware Workstation and in Virtualbox.

The installation seems to proceed properly (using EXT4, and EFI Grub) and i get a message that it has installed successfully. However when I reboot it passes GRUB, picks the correct Android installation, but it does not boot. I get the result seen in the screenshot below and then a blank screen with a blinking cursor.

enter image description here

I've seen somehow similar questions on Android-SE (here and here), but they use older versions of Android x86 and don't seem to have solutions that work for me.

The VMs in both VMware and Virtualbox have: HDD=4GB(IDE), RAM=2GB, 2 CPUs and they boot through EFI. I've tried nomodeset and xforcevesa in the Grub boot parameters but nothing seems to work.

The .iso does boot up though all the way to the GUI in Live mode (LiveCD).

Any assistance would be greatly appreciated. I have a feeling that the solution might be something linked to the graphics settings but i'm not exactly sure.

  • I share your feelings (same issue here). Due to some hints, I've even increased graphics memory to 32MB (no improvement). Some posts speak of the need for 2 partitions (1=primary 100MB for grub, 2=extended with the remaining space for Android), didn't help in my case. Another source suggested manually editing/creating the grub.cfg as menu.lst doesn't work (not tried that yet). My other try with Android 5.1 hung in the boot animation ("android" text), so I gave up after 15min. What OS setting is your install based on? I've used "other Linux", as that worked in the past. – Izzy May 10 '16 at 16:44
  • I tried "Ubuntu" and "FreeBSD" so far ... let me mess around some others and see if that helps. – Irvin H. May 10 '16 at 16:59
  • I saw a YouTube video where someone used Windows7, which really confused me. – Izzy May 10 '16 at 18:49
  • BTW: I've just tried again, for me it doesn't even boot into live mode (ends up at the same place then). Related issue on our sister site which I already mentioned: Android-x86 6.0 Marshmallow in VirtualBox:installation stuck on GRUB – Izzy May 10 '16 at 19:49
  • @Izzy : Actually from what i've read, the solution at the link in your previous post (and from a bit of experimentation) is not exactly correct, but it works. From my understanding it's actually the creation of the GPT boot sector that allows the Grub stuff to proceed, not the presence of 2 partitions. I read somewhere that the Android x86 partition formatting fails silently if the "Create/Modify partition is not done" first, leading to the grub installer hanging because the disk wasn't even formatted to begin with. (I'll add this "footnote" also to that link) – Irvin H. May 12 '16 at 12:10

10 Answers 10

44

Found the solution!

You have to edit menu.lst file. Here is how:

  1. boot in debug mode (usually the second option in boot menu)
  2. when booting stops (for me it just hangs there with flashing cursor and without any prompt) enter mount -o remount,rw /mnt
  3. enter cd /mnt/grub
  4. enter vi menu.lst
  5. press Shift+a
  6. right under the first boot entry find the line starting with kernel initrd=/in (your line might look different; it depends on Android version; in general just find the line that starts with kernel)
  7. at the end of the line type vga=834 nomodeset xforcevesa
  8. press ESC then :wq - these commands will save the file and quit vi
  9. enter cd /
  10. enter umount /mnt
  11. enter reboot -f

Now the system should reboot in the VESA mode of your choice.

This will enforces to use the VESA driver for X.

You can replace the vga=xxx by any number you want for your screen resolution. Also tested that 832 works fine (gives 800x600 resolution).

You can find all the VESA modes when you use the iso file and pick the boot option to boot in VESA mode - it will show the list with all modes (numbers are in hex and there is also a redundant letter in front of some modes - ignore it) and you can test them there immediately to see if it works and is good to use in this menu.lst fix, but you have to convert it from hex to dec first using any hex->dec converter.

  • 2
    +1, Confirmed to work for android-x86-6.0-r3.iso on VMware Workstation. – David Refoua Jan 14 '18 at 1:48
  • Is there a non-tedious alternativ which also does not allow errors that can be caused by 1 typo? – neverMind9 Aug 19 '18 at 23:09
  • Thanks a lot❗️ it's still working on Android 8 😊 – Yassine ElBadaoui Jan 13 at 4:42
  • 1
    Thanks a lot❗️ it's still working on Android 8.1 😊 – 井上智文 Feb 21 at 11:46
  • Works for Mashmellow Stable release 3. – Pasindu Jay Mar 21 at 4:53
6

I'd like to extend and improve @Jay Smith answer based on personal experience. He is right in the core thing that the cause of the issue is VGA resolution used by Android, but he is wrong in his assumption it is disposable fix and should be typed at each boot.
It can be made persistent, and should be! And I show you how:)

  1. First of all, install the Android from iso image correctly through the wizard steps.
  2. Do not use EFI GRUB during install.
  3. Do not use immediate Run Android_x86 option, instead select Reboot and eject the iso. The error mentioned by @Jay Smith

The big drawback of this approach is that the next time you try to boot from the hard drive, GRUB will not be able to find the image

is not related to VGA issue and should be dealt separately. I also met this error and full reinstall helped, so I assume this error is somehow connected with the Run option, 'cause when I selected Reboot I didn't face the error.

  1. After the install you will boot and will stuck into Android command prompt. Okay, go on then.
  2. Now you should try to pick up your correct resolution. It won't necessarily be 788 or 794, as they say here, it all depends on your hardware setup. For me 796, 794 and 792 worked for KitKat, Lollipop and Marshmallow images correspondingly, however your values could be different. Here is the table for linking GRUB VGA values to resolutions. To check what match you use trial and error method

Then on boot to GRUB screen choose e key to edit the option

enter image description here

There you will find a long-long string of options to which you should append your VGA option like that nomodeset vga=794

enter image description here

After editing press Enter and b to boot the desired bootrecord.

  1. Iterate these steps N times to find proper resolution. You will recognize that by the booting of Android:)
  2. O-la-la, excellent! We achieved the desired result and booted Android for one time. But this is only 50% of job. I guess you don't want to type this VGA crap each time? Okay, let's go on to persist our result.
  3. Now we need to edit GRUB config to add our desired resolution. While there are ways that allow doing this within the GRUB itself (i.e. debug mode, grub cmd) I wasn't able to get it to work and propose another 100% solution.

We need working Linux installation (physical or virtual, doesn't matter). The problem here is that GRUB folder cannot be accessed from inside Android as it's protected, and it should be accessed externally. And not from Windows because it doesn't recognize ext3/ext4 partitions, only from *nix OSes. So add this disk (VHD, VDI, VMDK or whatever) to your Linux installation for it to have access to android filesystem

  1. Access /grub/menu.lst. Usually it is located in root folder.

  2. There you'll find smth like

enter image description here

Append the desired VGA option to the bootrecord as we did earlier and that's it!

  1. Save the file.

We've done! Now you can reattach your android disk to virtual machine and happily use it.

4

I also had problems with Android x86 vitual box on a Windows 7 Pro x64 AMD machine. I suppose we are all going to have slightly different issues depending on our architecture/hardware but they all seem to be similiar root causes. I think more emphasis should be on the architecture/hardware then the host OS. Try 32bit without/with EFI set in System, leave hardware acceleration at default, make sure virtualisation is enabled in your bios. Don't enable 3D Graphics acceleration, you should get a warning if you enable 2D acceleration so don't enable that, if you get a black screen during initial setup try increasing the video memory up to 64mb. Finally you can download pre-built VM images here:

http://www.osboxes.org/android-x86/

All these little tweaks helped me successfully install Android x86 4.4 on a Windows 7 x64 Pro machine.

4

Some progress here, but not the real thing. The following allowed me to boot Android x86 6.0 under VirtualBox correctly - but only once:

1) When booting the installation image, the initial screen gives you four options. Move the cursor to the last one: Installation - Install Android-x86 to harddisk".

2) Press the [Tab] key for edit options.

3) Immediately after INSTALL=1 DEBUG= type vga=788

(Make sure there is a space between DEBUG= and vga=788.)

4) Press [Enter].

5) Proceed with the disk partitioning as described in many sites in the net.

6) When offered the options Run Android x86 and Reboot, choose Run Android x86. You should see ANDROID pulsating in big letters for a few minutes, and then the Android welcome screen will come on.

The big drawback of this approach is that the next time you try to boot from the hard drive, GRUB will not be able to find the image :-( Any help fixing this would be appreciated.

  • 1
    Unfortunately it's one-time workaround :(... – Suncatcher Feb 18 '17 at 18:19
0

Here is a YouTube video showing how to set VESA mode in Grub.

https://www.youtube.com/watch?v=JoMs-4bsygs

My other post was deleted for some reason, but if you want to find out if VESA/VIDEO is the reason your gui isn't coming up after install, then boot from the Android x86 ISO and select VESA mode (Live boot) and if you get a gui, then check out that youtube video. It explains perfectly how to setup your grub to boot the correct VESA mode.

0

Completely new to this but I just tried installing Android 6.0 on Workstation 12 Pro and on boot just stuck at command prompt ocassionaly flashing. Tried a couple of the suggestions from abvoe to no avail. Finally went into VM settings and ticked on 3D Graphics at which it warned that it was not supported. This then allowed me to select 32mb of graphic memory. Rebooted and it worked. Tried booting several more times just to prove it and it is still working. Hope this helps.

  • I tried the solution given by Spider5445 and it worked for Nougat as well...thanks a ton mate! :) – Kapil Vyas Mar 18 '17 at 10:01
0

While in the grub bootloader, press tab and change androidboot.hardware=android_x86 to androidboot.hardware=x86.

0

Your ISO is corrupt, please try redownloading it from The offical Android website link

0

Select "Yes" when it asks "Do you want to install boot loader GRUB".

GRUB

Now you can boot into Android. (Works even rebooted)

Reference: https://shellzero.wordpress.com/2015/10/27/how-to-install-android-on-vmware-fusion-mac-os-x/

-1

I had the same problem with the installation on my hard-disk and for me the following steps helped:

  • Like Jay mentioned above: On the installation medium I pressed the [Tab] key.
  • I wrote down exactly all the arguments like androidboot.hardware=android_x86_64 and DEBUG=2 etc. which are shown now for the installation medium boot menu entry.

  • I added all these arguments in my custom grub configuration and updated grub.

  • When booting I have to enter twice "exit" in the prompt of the console.

Doing this Android booted and started the window manager.

P.S.: Very uncool if an reviewer messes up the format of an answer and than even votes you down without getting the content.

protected by Community Mar 18 '17 at 11:54

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.