Android emulator: wifi connected, no internet - android-studio

It's been a while since I opened android studio. It's all good until today.
Today the android emulator can't connect to the internet (tried with chrome browser and my application in the emulator), altough it's wifi is connected.
How to fix this?
I already tried:
your_path_of_android_sdk\tools\emulator -avd -dns-server 8.8.8.8, but failed with message: PANIC: Missing emulator engine program for 'x86'
remove emulator, and add a new one from AVD manager
restart pc
reinstall android studio
emulator wifi settings (auto ip / dhcp):
Nexus 5S Api 28
ip address: 192.168.232.2
gateway: 192.168.232.1
subnetmask: 255.255.248.0
dns: 10.0.2.3
Is there a possibility I accidentally uninstall something important / removing network adapter in the 'Control Panel\Network and Internet\Network Connections' ?
( there is only one adapter in there )
Images:
wifi connected, no internet
emulator wifi settings
network adapter on win 7

Just found the solution
your_path_of_android_sdk\tools\emulator -avd -dns-server 8.8.8.8, but failed with message: PANIC: Missing emulator engine program for 'x86'
it does work! but i have to use emulator.exe in the "emulator" folder, not the one in the "tools" folder
the complete command is:
F:\AndroidSDK\emulator>emulator -avd Nexus_5X_API_28_x86 -dns-server 8.8.8.8
where Nexus_5X_API_28_x86 is my android emulator name (found in the avd manager in the android studio).

I was facing the same problem. So while using emulator in outside network it was working and then at my home network, same emulator was showing no internet. The possible cause is due to DNS.
But the solution I opted for this issue is to start emulator, turn off Wi-Fi and turn off data connection of emulator. And then turn on both again and see it will get connected to Internet eventually.

Related

Virtual-box failed to start VM VERR_INTNET_FLT_IF_NOT_FOUND

When I run vagrant up I get this error
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.
Command: ["startvm", "3ae7b70c-8ea1-417a-ab67-99aef96624f8", "--type", "headless"]
Stderr: VBoxManage.exe: error: Failed to open/create the internal network 'HostInterfaceNetworking-VirtualBox Host-Only Ethernet Adapter #2' (VERR_INTNET_FLT_IF_NOT_FOUND).
VBoxManage.exe: error: Failed to attach the network LUN (VERR_INTNET_FLT_IF_NOT_FOUND)
VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component ConsoleWrap, interface IConsole
I found the solution here: https://www.howtoforge.com/setup-a-local-wordpress-development-environment-with-vagrant/ which is to update the driver of VirtualBox Host-Only Ethernet Adapter
But the problem is I am remotely connected to the machine. So I am afraid that the network settings may lose my remote connection. Also, I cannot reboot the machine.
Is it safe to follow the steps mentioned in the link above which should not disconnect me? If not, is there any alternative way?
Recently I have struggled with this issue. I tried many times to solve the issue. Sometimes I was able to run my vagrant machines successfully but how I did was not sure because I was trying lot of options. But finally, I found a way to solve it. It's pretty simple and tricky.
Solution:
Once you get this error on your terminal, just open your computer network adaptors from the control panel. Select the adaptor which was created for that virtual box. simply disable once and enable again. then run vagrant up command. That's it. the problem is gone.
- Start --> Network status --> Change adaptor options --> (select the Ethernet adaptor - In my case it is Ethernet4)
- Right click --> Disable and right click --> Enable
- vagrant up
I faced the same issue and could not resolve it by changing properties in Network Adapters.
Then i reinstalled Virtual Machine by below command and it worked fine:
V:\softwares>VirtualBox-6.0.4-128413-Win.exe -msiparams NETWORKTYPE=NDIS5

Linux Opensuse Network Manager service is not running - OPENSSL_1_1_1d not found

I installed updates on my HP Opensuse Laptop and I cannot get wifi to connect anymore. The Wifi menu in the system tray is missing. I can see bluetooth, but not wifi. Upon investigation, Network Manager service is not running. When I try to run Networkmanager service from terminal using command NetworkManager --no-daemon, it comes up with the below error message.
NetworkManager: /lib64/libcrypto.so.1.1: version 'OPENSSL_1_1_1d' not found (required by /usr/lib64/libssh.so.4)
I have done some research and tried the following things.
Disable NetworkManager and Enable wicked service, but still the interfaces are complaining about NM not working.
When I check hwinfo, I can see the correct model and drivers for the wlan adapter.
I enabled the disabled adapters using ifup wlo1 as the interface was down when I checked ip addr
I was able to use iwlist wlo1 scan, I can see the networks in range, so the adapter is fine. It is an intel
I checked for bugs and there are some reports of similar behavior in 2019.
Use nmcli, it comes up with a message that "network manager is not running"
Tried to use YasT to disable NM and enable Wicked, but YasT does not bring up the Network screen any more after the update. It just spins and does nothing.
Ran Yast from terminal, it comes up with another message to report bug
Internal Error: Please report the bug report with logs. Run save_y2logs to get complete logs.
Caller: /uwr/lib64/ruby/vendor_ruby/2.6/0/yast/yast.rb:186:in "import_pure".
Details: Failed to import module 'PackageSystem' due to component cannot import namespace 'pkg'
Configuration:
uname -a
Linux linux-new 5.4.7-1-default #1 SMP Wed jan 1 07:55:50 UTC 2020 (34ebd01)
cat /etc/*release
LSB_VERSION="core-2.0-noarch:core-3.2-noarch:core-4.0-noarch:core-2.0-x86_64::core-3.2-x86_64:core-4.0-x86_64"
NAME="Opensuse Tumbleweed"
VERSION="20200110"
Does anyone have any ideas?

Android Studio : adb unable to connect to local host 5037 CreateFileW nul system cannot file specified

I know this is an duplicate question and believe me I have read every thread there is on this post
1) adb: CreateFileW 'null' failed: The system cannot find the specified file
2) Daemon not running. starting it now on port 5037 * Cannot open 'nul': The system cannot find the file specified
3) ddms: 'adb.exe,start-server' failed — run manually if necessary, Android Studio
I have tried EVERYTHING!!!
a)Uninstalling android studio,its emulators,sdk and deleting every folder saying android in my system
from C:/Users/${HOME}/AddData/Local & Roaming to even C:/Windows/[All System Folders(No adb was found in these folders)},Program Data etc.
b)Uninstalling and Reinstalling Platform Tools from Tools->SDK Manager->SDK Tools after android studio reinstallation
c)Manually going to ${ANDROID_SDK_HOME}/platform-tools folder, opening cmd as administrator and running
->adb start-server[Gives Same Error As Above]
->adb kill-server[Unable to connect to target machine ip xxx.xx.xx connection actively refused]
->adb start-server[Same Error As My Question]
d)Tried to verify if any apps running on port 5037
netstat -aon | findstr 5037
nothing
My specs are[No new updates are available for any of the below specifications]
1)Android Studio 3.5.1
2)Platform Tools 29.0.4
3)gradle 5.4.1
4)Windows 10 64 bit
Also i have geny motion installed but with no adb the emulator is not recognized in the device list
I know this issue was posted atleast an year back but i hope some new light has been shed on the issue
plzz help thank u in advanced

Cygwin Error : tcp_peer_send_blocking: send() to socket

My Cygwin installed on Windows 7 was working properly till I try to install a new package. The package installation failed. Then I keep getting this error every time I want to run my Open MPI program. I can successfully compile the program but cannot run it. I even remove and make a new installation without success.
Thanks for any hints. Below is the sample error message.
[Reloaded-PC:03900] [[3921,1],0] tcp_peer_send_blocking: send() to socket 13 failed: Transport endpoint is not connected (128)
[Reloaded-PC:03900] [[3921,1],0] tcp_peer_send_blocking: send() to socket 13 failed: Transport endpoint is not connected (128)
[Reloaded-PC:04676] [[3921,1],2] tcp_peer_send_blocking: send() to socket 13 failed: Transport endpoint is not connected (128)
[Reloaded-PC:04676] [[3921,1],2] tcp_peer_send_blocking: send() to socket 13 failed: Transport endpoint is not connected (128)
The problem is solved by disabling the unused network adapter in "Control Panel->Network and Internet->Network Connections".
It turned out the unused network adapter tried to get configured by DHCP and an IP address started with "169.254.X.X" was assigned to this adapter when DHCP fails. Somehow openmpi on Cygwin use that invalid IP address for establishing communication between processes.
I figured it out by looking at /tmp/openmpi-sessions-{username}/{PID of orterun}/contact.txt.
I had this same problem on Cygwin with OpenMPI 1.10.4.
Try adding "-report-uri -" to your mpirun command to see what IP address it's trying to use for connection:
mpirun -report-uri - -np 2 a.exe
It should print out a line that looks something like this:
568328192.0;tcp://192.168.10.103,169.254.247.11,0.0.0.0,0.0.0.0,0.0.0.0:55600
If the first IP address after the "tcp://" is not a current valid address for your machine, that's the problem and things are likely to break (even if the correct IP appears later in the list). Apparently ORTE is not smart enough to order the interfaces based on what is actually enabled and online.
If the wrong IP corresponds to an old/disabled interface, uninstall it (if possible) using the windows network connections control panel.
In my case, the first address was a DHCP address for an old hardware adapter I'd removed and thrown away long ago (but apparently not uninstalled in software). Windows normally hides such removed-but-not-uninstalled interfaces in the control panel, but the settings remain in the registry under:
HKLM\SYSTEM\CurrentControlSet\services\Tcpip\Parameters\Interfaces\
Search in that registry subkey for the bogus IP address and you are likely to find the problematic interface. I fixed mine by changing the IP address in that registry key to match my current static IP, but uninstalling the interface entirely would probably also work.
I had the same problem with openmpi v 1.8.8 (which is the default version of the package installed by cygwin). Manually going back to version 1.8.6 fixed the issue for me.
I just encountered this problem and in my case I had to disable the "VirtualBox Host-Only Network" adapter (I recently installed virtualbox and have not used openmpi in cygwin after that until today).
1. Open the Cygwin terminal.
mpicc --version
mpirun --version
If not execute, follow the document below and reinstall everything. Document
2. Try turning off Bluetooth and test your program again.
3. Try closing the Wifi and test your program again (you can connect to the wired internete)
4. Open C:\Windows\System32\drivers\etc\hosts
add line
127.0.0.1 localhost cygdrive wpad
and test your program again.
5. If you have a virtual network like VirtualBox or similar, turn off the control panel and test your program again.
6. If possible, uninstall VirtualBox completely. Restart your computer and test your program again.
7. Try turning off the Windows Firewall and test your program again.
The above steps solved both the "tcp_peer_send_blocking: send () to socket 12 failed: transport endpoint is not connected" error and the slowness problem in MPI for Windows 10 - Cygwin.

Cannot connect to Android Wear Device via bluetooth

I want to connect my Samsung Gear Live with my Samsung Smartphone Device and am trying to follow the giveninstruction. Also kept searching on stackoverflow with similar problems, but it seems that it is something else.
So this what happens when I am using the terminal to connect:
Denjos-MacBook-Pro-2:platform-tools Denjo$ cd /Users/Denjo/Library/Android/sdk/platform-tools
Denjos-MacBook-Pro-2:platform-tools Denjo$ ./adb forward tcp:4444 localabstract:/adb-hub
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
error: device not found
error: device not found
Denjos-MacBook-Pro-2:platform-tools Denjo$
What am I probably doing wrong?
I solved it this way, that I changed the USB-cord.

Resources