-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
checkout@v3 failed on windows2022 self-hosted runner, reporting Error: File was unable to be removed Error: EBUSY: resource busy or locked #1230
Comments
It's possible this will get fixed by actions/toolkit#1373 I'll check with the authors. |
Some background: On Windows we found that Can you tell us more about the file and your workflow or show us logs from a run? I would want to know what holds open the lock and how the file was opened. This way we can make sure that this gets closed before deleting the repository or we have additional logic to handle this. |
Run actions/checkout@main Error: File was unable to be removed Error: EBUSY: resource busy or locked, rmdir 'C:\actions-runner\windows2022-003_work_temp\5d9f2d3d-6f40-481b-89c0-1e89b725b6e2' |
tested actions/checkout/v3.3.0, occur below error: Error: Command failed: C:\Windows\system32\cmd.exe /s /c "rd /s /q "%inputPath%""
code: 32, |
If v3.3.0 fails, then it is not related to the change above. What's the minimum workflow I can use to reproduce this? The following is not enough.
|
I ran into this issue today as well. Rolling back to checkout@v2 solved it for me too. |
I found that the dcd71f6 commit caused this issue。 |
facing this similar error when using the version
Error: File was unable to be removed Error: EBUSY: resource busy or locked, rmdir 'C:\actions-runner_work_temp\8ea00981-3dd3-40c7-b56b-eaf8ad9c2b3d' Are there some windows OS settings which can cause this issue ? Tried with v2 v3 and latest one also facing the same issue |
Running this in PowerShell as Administrator will fix it:
|
Hi @vladimir-voinea , I have the same issue , In my github repository there is one bash file which I would like to execute using the github actions , In this bash file there is one desktop application which I want to execute locally but I am getting error. throw new Error( Error: File was unable to be removed Error: EBUSY: resource busy or locked, rmdir Could you please tell me what I can do about it or Is it possible from the github action to start the desktop application and execute it using the bash file in the repository |
The same issue started to appear on all versions of checkour 2, 3 & 4. Error: File was unable to be removed Error: EBUSY: resource busy or locked, rmdir 'C:\actions-runner_work_temp\f054c8eb-74f7-4204-a725-048ba2feb4ef' Node.js v20.8.1` |
I've just found out that when I removed the folder from the gitconfig.safe section it begun to work fine again. |
I have tried v3 and v4 , I'm facing the same issues, but when I tried v2, its working fine without any errors |
This is also failing for v2-v4 for me, same reason - random GUID folder under _work.
|
I encountered the same problem in version v3. |
|
For those who may have run out of ideas: set-safe-directory: false |
checkout@v3 reporting below error on my windows2022 self-hosted runner, but checkout@v2 works ok!
C:\actions-runner\windows2022-003_work_actions\actions\checkout\v3\dist\index.js:6844
throw new Error(
File was unable to be removed ${err}
);^
Error: File was unable to be removed Error: EBUSY: resource busy or locked, rmdir 'C:\actions-runner\windows2022-003_work_temp\dcd7fd89-dafd-4a46-b292-3c1c71a82794'
at Object. (C:\actions-runner\windows2022-003_work_actions\actions\checkout\v3\dist\index.js:6844:19)
at Generator.throw ()
at rejected (C:\actions-runner\windows2022-003_work_actions\actions\checkout\v3\dist\index.js:6738:65)
The text was updated successfully, but these errors were encountered: