解决Android Studio 升级时提示 Connection failed. Please check your network connection and try again问题

一,问题:

   无论mac还是windows可能都会出现这个问题,解决方案大同小异,就是修改VMOptions而已。

 

 

解决方案:

Windows:

在\Android Studio\bin目录下找到 studio.exe.vmoptions文件。64系统找到相应的studio64.exe.vmoptions文件。添加以下两句:

-Didea.updates.url=http://dl.google.com/android/studio/patches/updates.xml
-Didea.patches.url=http://dl.google.com/android/studio/patches/

重启后就可以更新使用

Mac:

找到Android Studio的安装包,然后显示包内容。

在/Applications/Android Stuiod.app/Contents目录。找到info.plist

然后找到key为JVMOptions,在其目录下找到key 为VMOptions 然后编辑其value,

在最前面加入下面内容:

-Didea.patches.url=http://dl.google.com/android/studio/patches/  -Didea.updates.url=http://dl.google.com/android/studio/patches/updates.xml

每个选项之间要保留空格。

保存,重启Android Studio即可

posted @ 2015-01-07 12:00  UFreedom  阅读(3577)  评论(0编辑  收藏  举报