Android SDK Manager SDK Manager.exe下载全部平台时更新包的时候出现无法下载的情况

来源:互联网 发布:基金持仓成本算法 编辑:程序博客网 时间:2024/05/22 10:53

转自:http://blog.csdn.net/cyj5366/article/details/9766993

Done loading packages.
Fetching https://dl-ssl.google.com/android/repository/addons_list-2.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/addons_list-2.xml, reason: Unknown Host dl-ssl.google.com
Fetched Add-ons List successfully
Fetching URL: https://dl-ssl.google.com/android/repository/repository-8.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/repository-8.xml, reason: IO Unknown Host dl-ssl.google.com
Fetching URL: https://dl-ssl.google.com/android/repository/addon.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/addon.xml, reason: IO Unknown Host dl-ssl.google.com
Fetching URL: https://dl-ssl.google.com/android/repository/extras/intel/addon.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/extras/intel/addon.xml, reason: IO Unknown Host dl-ssl.google.com
Fetching URL: https://dl-ssl.google.com/android/repository/sys-img.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/sys-img.xml, reason: IO Unknown Host dl-ssl.google.com
Fetching URL: https://dl-ssl.google.com/android/repository/sys-img/mips/sys-img.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/sys-img/mips/sys-img.xml, reason: IO Unknown Host dl-ssl.google.com
Fetching URL: https://dl-ssl.google.com/android/repository/sys-img/x86/sys-img.xml
Failed to fetch URL https://dl-ssl.google.com/android/repository/sys-img/x86/sys-img.xml, reason: IO Unknown Host dl-ssl.google.com
Done loading packages.

 
解决办法:
设置本地hosts
windows里hosts位置在C:\Windows\System32\drivers\etc,找到hosts文件

直接在hosts文件的最后加一行:

74.125.237.1 dl-ssl.google.com

重新打开SDK Manager.exe就可以下载了

例如:


# Copyright (c) 1993-2009 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
#      102.54.94.97     rhino.acme.com          # source server
#       38.25.63.10     x.acme.com              # x client host


# localhost name resolution is handled within DNS itself.
# 127.0.0.1       localhost
# ::1             localhost
203.208.46.146 dl.google.com
203.208.46.146 dl-ssl.google.com



0 0