-
Notifications
You must be signed in to change notification settings - Fork 286
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
Unable to rename open file on Windows volume mount (grpc-fuse) #5565
Comments
Thanks for the easy repro code sample. We know of problems in Go to golang/go#32088 and golang/go#34681 that doesn't allow to open files with It doesn't seem to happen with samba share in DD 2.1.0.5, it also works in DD 2.2.0.0 and the WSL2 backend (9P share). As we're coming closer to the Windows 10 2004 release our focus is the WSL2 backend. |
Thanks for the detailed response @StefanScherer! For some context, I originally encountered the issue when trying to run RethinkDB - https://hub.docker.com/_/rethinkdb and share the databases' data directory with Windows so that it would persist. It would try to rename a temporary file (which it also had open at the same time) - https://github.com/rethinkdb/rethinkdb/blob/98fd78409095a25b04dcaf0eadd6719f381a7d7e/src/serializer/log/log_serializer.cc#L88 |
Possible duplicate: #5665 |
This is fixed in 2.2.0.4. |
Closed issues are locked after 30 days of inactivity. If you have found a problem that seems similar to this, please open a new issue. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
Expected behavior
When renaming an open file, I expect the
renameat
syscall to complete successfully.Actual behavior
When renaming an open file, the
renameat
syscall fails with-1 EBUSY (Device or resource busy)
.Information
This problem is easily reproducible. I've come up with the following Go code that can be used to replicate:
The code above creates and opens a file in the current directory -
./test
withopenat
. It will then print the fd of the file, and then attempt to rename the file to./test2
usingrenameat
.Under a normal Linux system, this completes without issue. When you run it on a filesystem that is a Windows volume mount, the code will panic due to an error experienced -
Steps to reproduce the behavior
C:\
docker run -it --rm -v "/host_mnt/c/Users/Alex Price/go/src/github.com/awprice/docker-for-win-grpc-bug:/shared" golang:1.13 bash
cd /shared
go run main.go
You should experience the issue:
We can double check that
/shared
is on the grpcfuse filesystem:If you move the go code to a non-shared directory and run it, it should complete without issue:
I recommend also using
strace
on the Go code to further understand what is happening.The text was updated successfully, but these errors were encountered: