Communication between Android Emulator on VM and Host - android-emulator

I have an Android Emulator running on an Ubuntu VM that is hosted on Win7.
Now, I want to reach an IP address that is hosted on my Win7 from the Android Emulator.
I can reach the address from the Ubuntu guest machine, but I can't from the emulator.
Win7 Host IP - 10.100.102.2
Ubuntu Guest IP - 10.0.2.15 (NAT Network Adapter)
IP Address - 10.100.102.2:21000
I'm guessing that I have to add a route in the emulator for it to work. I've tried to route throught these special addresses, but it didn't work :\
ip route add 10.100.102.2/32 via 10.0.2.1 dev eth0
Thanks!

Well, the problem wasn't with the routing.
It was with the fact that both the VM and the Emulator were configured with a NAT Network Adapter under the same subnet 10.0.2.0/24.
The moment I changed the VMs network adapter to Bridged, everything started to work.

Related

Why am I unable to ping my host machine from vm machine even though the network is bridge?

I have been facing an issue with VMware which is unable to ping host machine from Guest Machin, but I'm able to ping guest machine from host machine.
Note: Here one more interesting matter is I could able to ping my host machine from guest machine with NAT network, but I couldn't ping my guest machine from host machine.
Your question is not clear at all.
In any case, you might wish yo specify what OS you are using in both nodes.
Firewall issues? You could try to disable Windows firewall for instance and locate where is the issue.
Could you give some basic data of the IP address of both nodes when the set up is in bridge mode?
Instead of disabling the firewall. Enable Rule "File and Printer Sharing (Echo Request - ICMPv4-In)" from Inbound Rules on both Host and the VMWare Workstation. In some host machines or VMWare Workstation you may find multiple Rules with the same name "File and Printer Sharing (Echo Request - ICMPv4-In)", make sure you enable all.

Cannot browse a local easyphp web server using the local IP address

I am running easyphp with apache version 2.4.18 x86 (32-bit) on Windows 10.
On the PC where easyphp is running, I can connect using either localhost or http://computername, but if I try to connect through the local IP address which is http://192.168.0.10, I get a white page without any error message.
And the most strange thing, if I plug an iPhone (USB) with a shared connexion in the PC (the PC gets 2 network connections), then I can access to http://192.168.0.10 through the PC (still the wifi IP local address and not the iPhone local network address).
If I unplug the iPhone, then it fails again to connect to http://192.168.0.10.
Any explanation ?
So it was a firewall problem.
Evene when desactivating the firewall, the web site was not reachable.
I've added manually the
EasyPHP16\eds-binaries\httpserver\apache2418vc11x86x160927105506\bin\eds-httpserver.exe
in the Windows firewall rules, and it worked.
The two strange things is that disabling the firewall did not arrange anything, and lanching the webserver did not pop up the firewall dialog.
Hope this helps.

DNS problems with local hosts especially with Iphone/Ipad

I have some problems communicating with different devices each other in my local network. I suggest some DNS problems or incorrect DNS settings
First of all, a short overview of my devices:
Router: Speedport W 921V (latest Firmware 1.22.) using also dyndns for remote operation
File-/Web-Server: Debian Squeeze running samba and apache
Client1: Computer using Win 7 Pro
Client2: Iphone/Ipad
Internet works fine on all devices! All clients have set the DNS to the IP of my router. The router also has the settings for port forwarding from port 80 to port 80 of my Webserver as well for port 8080. To access to my Webserver outside my local networks also works fine, but....
Problem 1) Resolving public dyndns-address
When I ping my public address mysubdomain.dyndns-home.com inside my local network, the IP will be resolved correctly without any timeout problems on all devices, but when I use my public address in a browser (Chrome, Firefox, IE) there is a timeout error message or server down message. This is the same behavior on all devices. So why can I not use my public address in my local network? To change that, what do I have to change?
Problem 2) Resolving local devices on Iphone/Ipad
Because I can not use my public address in my local network I want to communicate by my local device names. So all my devices are registered by their mac-address in the router. When I log into my router I can see all devices and their IP-addresses which are currently running. So if the router is the DNS for my clients, the router should resolve the local device names. That works so far for the Computers running Windows or Linux. But on my Iphone or Ipad the names will not be resolved. I also tried to refresh the lease or to forget the network and reconnect again, but still I can not communicate with my Iphone/Ipad and my other devices. So what can I do to resolve the names on my Iphone/Ipad?
Thanks for your help
1) Because you are in your local network you have to use private ip (you can see private ip using ipconfig on windows or ifconfig command line on linux). The public ip is for all others computers on the network. If you want test that the server works correctly you can use a proxy (like www.anonymouse.org)

Running a server in Parallels virtual machine. Is it possible for the host to access?

I am running a web server in my Windows 7 guest OS, while I want to access it from my Mac host OS.
The web server is running and I can access it from my guest OS, but not from its host.
I'm using Parallels Desktop and I've tried to change the networking mode from shared, bridged, to host-only with no result.
This is for development sake, so I just need it to be at least accessible to my host OS.
Is this actually possible with Parallels, or should I keep an eye on other VM engine?
You want to put your guest into "bridged" networking mode. This will allow it to obtain an IP address on the same network as your host OS (from your router via DHCP or statically configured).
See this:
Shared Networking – the recommended type of networking for the VM. Your virtual machine will share whatever network connection is used by
your Mac. You will be able to access the network from the VM as long
your Mac OS X is connected to the network. The only limitation of this
mode is that the VM is not visible from the external network
Bridged Networking – uses your network adapter. You should choose this mode if you want to access the VM from the external network.
Please keep in mind that your network configuration should allow using
DHCP to assign IP address for the VM, or you should obtain a static IP
for the VM and set it in the guest OS.

Android Emulator Networking

How can I make Android Emulator and the host machine (Ubuntu 9.10) connected together to the same network?
For example
Android Emulator IP Address : 10.0.2.15
Ubuntu Host IP Address: 10.0.2.16
Thanks in advance
You have to use port forwarding using either 'adb forward' tool of Android or using 'redir add' from the emulator console
Android uses an internal router through which it accesses the host network connection. In that router, there is a firewall to avoid communication to the external world. If you need to enable communication between your emulator and the host, you need to use port forwarding option that is provided in Android emulator. Use telnet localhost port# in Android console. port# is usually appearing in the title bar of the emulator window. Numbers such as 5554, 5556, 5557 and so on.
Use add <protocol>:<host-port>:<guest-port> to define a port forwarding rule for your router. Protocol is udp/tcp and host port is the port of your computer and guest port is the port of your emulator. So, if you want to transfer all the http call to theh ost use add tcp:80:8080
More information is here