Can't update Android Studio - Access Denied and java.io.FileNotFoundException

前端 未结 11 1974
青春惊慌失措
青春惊慌失措 2021-02-18 15:00

I\'m trying to update Android Studio from 0.5.1 to 0.5.2 on two separate Windows machines, one with Windows 7 Pro 64-bit and one with Windows 7 Enterprise 64-bit.

I get

相关标签:
11条回答
  • 2021-02-18 15:26

    I had the same problem - update from 0.6.0 to 0.6.1 After pressed button "Update", Android studio restarted and started to update. After this I got "Error message". I pressed "Retry" button - it was unsuccessful. Then I waited about 2 minutes (in my studio after start Gradle is working) and pressed again "Retry" - Done! :) Everything was updated. So in my case the reason of problem was Gradle that works after start of Android studio.

    0 讨论(0)
  • 2021-02-18 15:28

    This happened with me updating from 0.6.0 to 0.6.1. I had attempted to open AS in admin mode with every other application closed but the update still failed for me. I also tried deleting the Temp folder.

    Eventually I noticed in the task manager when everything was closed I still had a sizeable java.exe still running in the background for some reason.

    What I did was open AS in admin mode, run the update and let it fail, claiming a file is locked / access is denied or something similar. Open the task manager and I noticed 2 java.exe processes running. For me the smaller one (about 200k) was the AS updater utility itself. But if I killed the larger one (about 600k), and hit retry, the update went through without issue.

    0 讨论(0)
  • 2021-02-18 15:28

    I had this same issue updating from 2.2 to 2.2.1. My solution was restarting Windows

    0 讨论(0)
  • 2021-02-18 15:29

    You might also try to give your user permission to the folder.

    1. Right click the "android-studio" folder and select "Properties"
    2. Change to "Security" tab
    3. Click the "Edit" Button
    4. Select the group/user from the "Group or user names" list
      1. You can select/add your username to this list -or-
      2. Select the group "Users" (or the group where your user is)
    5. Select the "Full control" checkbox
    6. Click "Apply" and wait

    You're done.

    0 讨论(0)
  • 2021-02-18 15:32

    I've stuck at the same issue, but I solved it by running this script in elevated console: Program Files\Android\android-studio\bin\update_studio.bat

    0 讨论(0)
提交回复
热议问题