Android SDK Manager won't update: connection to https://dl-ssl.google.com refused

后端 未结 23 2475
后悔当初
后悔当初 2020-12-13 08:50

This is the same problem as a number of other have reported, e.g.

Failed to fetch URL https://dl-ssl.google.com/android/repository/addons_list-1.xml, reason: Connect

23条回答
  •  北荒
    北荒 (楼主)
    2020-12-13 09:37

    The reason sudo works on linux and Mac OS X is that sometimes the permisions in ~/.android get misconfigured. If you are having this problem over and over again, and you would rather not type sudo every time you want to update your sdk, go to ~/.android and ensure that your account owns and has permissions to read and write all the files.

    In my case I found that root owned several folders including the cache directory, cd ~/.android sudo chown -R * fixed the problem for me. If you are touchy about the security of your system, you can also specify a group like: sudo chown -R : * AND

    you could also specify the individual files and directories that need to be changed if you don't like the wild card. sudo chown --R cache for instance.

    Thanks to the folks here for figuring it out.

提交回复
热议问题