Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

no network in Android x86 on VirtualBox 4.1.2

My issue is nearly identical to this question. I tried those solution and none worked. But I am using a different Android x86 image. I'm using the ICS (4.0-RC1) asus_laptop image. (I tried a different image previously and couldn't get it to install.)

I installed VirtualBox 4.1.12 on Kubuntu 12.04. I followed these steps and installed the android-x86-4.0-RC1-asus_laptop.iso image in my VM. It boots up and works correctly except for networking.

Alt-F1 netcfg shows no interfaces up except the lo (127.0.0.1). eth0, which should be available, is not shown. That prevents me from trying the solution here.

New references I'm checking out:

  • Android ICS x86 on VirtualBox with Internet Connection
  • http://groups.google.com/group/android-x86/browse_thread/thread/30fa23d81cddfab1/2e480f6b9cbf773d
  • How to setup network for Android Honeycomb in VirtualBox?
like image 565
MountainX Avatar asked Apr 09 '12 05:04

MountainX


2 Answers

The following works very good for me

sudo vi /etc/init.sh 

add 4 lines below to init.sh

netcfg eth0 dhcp echo nameserver <ip> > /etc/resolv.conf dnsmasq  setprop net.dns1 8.8.8.8 

on virtualbox set the network interface to bridged (PCnet Fast III) and that's all.

like image 187
aafirvida Avatar answered Sep 17 '22 10:09

aafirvida


Update: If Android x86 does not work well for you, you might want to look at AndroVM. I run it in VirtualBox and have had no hardware related issues.

Real Answer:

Somewhat of a follow-up answer since I can't add comments yet. I think getting this setup is highly dependent on your host hardware. I am not using hardware that perfectly fits any of the current ISOs. So I tested all of them with all Ethernet settings to see what would work.

On a Dell Latitude D820 here is what I got:

  • eeepc - Bridged Adapter with PCnet-PCI II
  • tegav2 - NAT adapter with PCnet-PCI III
  • amd_brazos - No CPU support
  • asus_laptop - No eth0 option for any Ethernet adapter setting
  • s104t - Would not boot

For the two ISOs that would work for me (eeepc and tegav2), I added the following two lines to /etc/init.sh (as per the other answer)

netcfg eth0 dhcp setprop net.dns1 8.8.8.8 
like image 43
CatShoes Avatar answered Sep 17 '22 10:09

CatShoes