1,Android SDK无法更新或repo文件无法下载:
解决方法:(如果hosts文件只读,则用sudo打开)
74.125.237.1 dl-ssl.google.com
2,在使用repo sync下载cm源码时提示以下错误:
error: Failed connect to android.googlesource.com:443;Connection refused while accessinghttps://android.googlesource.com/a/platform/frameworks/base/info/refs
fatal: HTTP request failed
error: Cannot fetch platform/tools/motodev
error: Cannot fetch platform/frameworks/base
error: Cannot fetch platform/prebuilts/sdk
error: Exited sync due to fetch errors
解决方法:编辑/etc/hosts文件
增加下面内容,保存:
74.125.31.82 www.googlesource.com74.125.31.82 android.googlesource.com
203.208.46.172 cache.pack.google.com
59.24.3.173 cache.pack.google.com
地址可能会变,ping 地址能通才有用。