'Download API 21 on Android Studio : SDK Manager doesn't work
I develop a project on Android Studio. This project is based on the API 21, but i have download a API 22.
So, i try to download the api 21 with SDK Manager, but i have some errors like this :
Failed to fetch URL http://dl.google.com/android/repository/repository-10.xml, reason: Socket Permission denied: connect
already try :
go to http://dl.google.com/android/repository/ and download sources-22_r01.zip, and dezip the .zip in D:\LOGICIEL\AndroidSDKLocation\sources\android-21 Then, SDK Manager just found 'source for API 21', but i can't configure my emulator with SDK 21.
Lauch in admin
disable my firewall / Kaspersky
in the past, i have a proxy settings. Maybe there are still some settings somewhere ? Already chek in studio.exe.vmoptions and studio64.exe.vmoptions :nothing
try to force https in option SDK
set "no proxy" in android studio"
is there any log where i can find a error when i try to download/update in Android Studio ?
Thanks a lot for reading. I hape you will help me :)
Solution 1:[1]
I have the same problem all the time and usually I use proxy to get access to Google repository for downloading sources and stuff. but if you want to install it manually you have to download related "System Images" ("sources" won't be enough for the emulator). it's normally called "ARM EABI v7a System Image" or "intel x86 Atom System Image" in SDK Manager.
In case you want to use intel-based emulator, you have to download and install HAXM too which can be downloaded from intel's website.
but it's far easier to use "Android SDK Manager" through a proxy than to do all this manually :)
Edit: check this option in Android Studio for proxy issues : File > Settings > HTTP Proxy (under "IDE Settings") > set it to "no proxy" if want to use your own IP.
Solution 2:[2]
I had a proxy issue with Android SDK Manager. You could try the following.
Search for the file:
C:\Users\<USERNAME>\.android\androidtool.cfg
Inside you have to add
-Djava.net.useSystemProxies=true
System.setProperty("java.net.useSystemProxies", "true");
In addition you have to fill in your proxy into the given settings:
http.proxyPort=<your Proxy Port>
http.proxyHost=<your Proxy URL / IP>
I have no clue why the latter is necessary. But after that your Android SDK Manager should be able to connect to the internet and the manager will ask for your credentials.
Solution 3:[3]
To download SDK versions inside android studio, go to Tools --> Android --> SDK manager then select the specific SDK versions you wish to downlaod.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | |
| Solution 2 | |
| Solution 3 | unknown_seagull |
