Skip to content

Instantly share code, notes, and snippets.

@GabLeRoux
Last active March 10, 2016 20:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GabLeRoux/f8dd2c93d097ef6bd29a to your computer and use it in GitHub Desktop.
Save GabLeRoux/f8dd2c93d097ef6bd29a to your computer and use it in GitHub Desktop.
Get two network devices on android virtual image [wip]
# Get android vm image from
# http://www.osboxes.org/android-x86/
# 1. Go to box preferences
# add second card (first one should be nat)
# 2. Start android vm
# 3. Google "android terminal emulator"
# grab the one on the second crappy website (not play store)
# Make sure you allo install from unknown source... :(
# execute these commands on the vm
# 4. Get into sudo mode
su
# 4. Check network configuration
netcfg
# 5. Locate eth1 (it will be down)
# enable it
ip l set eth1 up
# 6. Go to virtualbox network preferences (not the vm preferences, virtualbox preferences)
# check out ipv4 adress HOST-only Network Details
# will be something like 192.168.33.1
# now set ip to vm eth1 in the same range
ip addr add 192.168.33.100/24 dev eth1
# 7. Now both vm and host should be able to see each other
# from vm
ping 192.168.33.1
# from host
ping 192.168.33.100
# 8. Connect with adb and enjoy your logs
adb connect 192.168.33.100
adb logcat
# sadly for now, I can only see host from guest box (android) so adb fails, to be continued :'(
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment