Just installed Android Studio 3 on Mac OS High Sierra 10.13.2 and created a virtual device. Lunched the emulator, but it seems that there is no internet connection. Please check the screen grab. What am I missing ?
Asked
Active
Viewed 8,998 times
22
Gianfranco P.
- 8,605
- 5
- 46
- 64
Stefan Ciprian Hotoleanu
- 2,042
- 1
- 22
- 29
-
Possible duplicate of [Internet stopped working on Android Emulator (Mac OS)](https://stackoverflow.com/questions/44535500/internet-stopped-working-on-android-emulator-mac-os) – lenooh Nov 23 '18 at 11:08
1 Answers
61
That occasionally happens to me as well. Just use different DNS and it'll work.
Go to your android-sdk/emulator and run, this will start the emulator:
./emulator -avd YOUR_EMULATOR_NAME -dns-server 8.8.8.8,8.8.4.4
You can find the emulator name you need by running the command
./emulator -list-avds
Alexander Farber
- 19,827
- 73
- 224
- 393
insa_c
- 2,661
- 1
- 14
- 11
-
6You are lifesaver! I have changed DNS in MacOS setting and it works from gui now. – Mateusz Kaflowski Feb 08 '18 at 16:03
-
Oh man, Thanks a lot. I 've just had a question: How to do this in UI of emulator? – RoShan Shan Sep 17 '19 at 06:27
-
I got `** Unknown exception behavior: 0` when setting 2 IP addresses (version `30.0.5`). One did the trick. It had some 10.x IP address for the DNS for some reason. – Gianfranco P. May 21 '20 at 09:36