Android Studio I keep getting Gradle error "The process cannot access the file because it is being used by another process"-ThrowExceptions

Exception or error:

I can import a sample app project, try to build it and I keep getting this error. Not always the same file but a new temp file each time. I’ve tried several different samples. I’ve been programming for 30+ years and feel completely clueless. Only clue seems to be the Windows Task Manager shows 99% to 100% CPU usage when it gives the error and ends the build.

How to solve:

Do This

File -> Invalidate Caches / Restart.. -> Invalidate/ Restart


Just clean the project and have a run ! It would work ….


When this happens to me on Windows 8, I open the task manager

task manager

and simply kill all the instances of “openjdk platform binary”


I have the same issue’s.Even I tried all the solution mentioned here it didn’t work.Even I can’t delete the signin file as running android studio administrative mode.I see a notification at bottom right side of the IDE update gradle pluggin.So update gradle pluggin usually worked for meenter image description here


I had the same problem and in my case it is due to multiple Java Run times (JRE’s). Try switching between JRE’s in android studio or use only one Java runtime.

Hope it fix the problem. Happy Coding..

enter image description here


The all files in “app/build” directory in project folder. This will fix the error.

Leave a Reply

Your email address will not be published. Required fields are marked *