解决安卓SDK更新dl-ssl.google.com无法连接

本文介绍了解决访问dl-ssl.google.com导致Android SDK下载失败的问题,通过使用站长工具网站进行ping测试并修改hosts文件,确保成功下载SDK包。
搭建Android就会用到Android SDK,而安装SDK就需要在线下载SDK包,经常会出现dl-ssl.google.com拒绝访问导致不能下载。解决方法:
1.  访问 http://tool.chinaz.com/站长工具网站,选择超级PING。
2.  把域名 dl-ssl.google.com 粘贴进去,这里注意的是监测点只选择“海外”,点击查询。
3.  接下来就能看到有好几个可以PING通的IP地址。
4.  此时可以用cmd ping 命令来测试这些IP是否能ping通,发现一个可以ping通的了, 下面就是更改Host了。
5. 进入C:\Windows\System32\drivers\etc下,用记事本打开host文件换行添加:
74.125.23.190 刚ping通的IP)  dl-ssl.google.com
亲测有效。
1 actionable task: 1 up-to-date bdlf@bdlf-desktop:~/AndroidUSBClient$ rm -rf ~/.gradle/caches/ bdlf@bdlf-desktop:~/AndroidUSBClient$ ./gradlew assembleDebug This version only understands SDK XML versions up to 3 but an SDK XML file of version 4 was encountered. This can happen if you use versions of Android Studio and the command-line tools that were released at different times. IOException: https://dl.google.com/android/repository/addons_list-5.xml javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed IOException: https://dl.google.com/android/repository/addons_list-4.xml javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed IOException: https://dl.google.com/android/repository/addons_list-3.xml javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed IOException: https://dl.google.com/android/repository/addons_list-2.xml javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed IOException: https://dl.google.com/android/repository/addons_list-1.xml javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed Failed to download any source lists! IO exception while downloading manifest: javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:131) at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:378) at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:321) 如何解决
最新发布
05-20
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值