Skip to content
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

Bash lock up when reading/writing files #1675

Closed
soda0289 opened this issue Feb 6, 2017 · 16 comments

Comments

Projects
None yet
9 participants
@soda0289
Copy link

commented Feb 6, 2017

Starting with build 15025 bash will lock up, not responded to key presses, when trying to list or edit files that are system linked to the c: drive. For example my home directory has a system link to my workspace. ln -s /mnt/c/users/reyad/workspace ~/workspace It will for a while but then lock up when trying to save or read a file. I cannot kill the process with task manager. When I try to restart LxssManager it gets stuck in the Stopping state forever. Only a restart will fix the issue. I can still open bash.exe an list directories that are in my home directory but not the directory I system linked.

@benhillis

This comment has been minimized.

Copy link
Member

commented Feb 6, 2017

There are currently a couple of deadlock issues in DrvFs (/mnt/...) that have been fixed internally but not yet released via Insider builds. I'm confident this is one of those issues. Could you provide some repro steps so I can verify your exact case is fixed?

@benhillis benhillis added the need-repro label Feb 6, 2017

@soda0289

This comment has been minimized.

Copy link
Author

commented Feb 6, 2017

I do not have exact steps to reproduce. When I use vim to edit a file in a linked directory of the C drive it will lock up after a few minutes. I use a few vim plugins that read and update files in the background, mostly linters and compilers. Not sure exactly which operation is causing the deadlock. I will update this issue as soon as have a better idea.

@masterwok

This comment has been minimized.

Copy link

commented Feb 8, 2017

I'm also experiencing this deadlock. I recently upgraded to 15025 to get nodemon working. I'm hitting it when trying to install packages with npm and also when I try to start my node application. Once the deadlock occurs the only way to get bash going again is to restart Windows as I'm unable to kill the bash process.

@soda0289

This comment has been minimized.

Copy link
Author

commented Feb 8, 2017

I was also able to reproduce the problem when performing an npm install. After it locks up I cannot run ls on the linked directory. I can ls on /mnt/c/ but not on the linked directory /mnt/c/Users/reyad/Workspace/. What is really strange is that if i use strace on ls the commands it runs successfully.

@tyscorp

This comment has been minimized.

Copy link

commented Feb 8, 2017

I'm getting this with npm install also.

@benhillis

This comment has been minimized.

Copy link
Member

commented Feb 8, 2017

As I mentioned above we've identified a few deadlocks that would be causing this. We have fast-tracked the fix and it should be in an insider build soon (hopefully the next one).

@soda0289

This comment has been minimized.

Copy link
Author

commented Feb 8, 2017

As root I can lock it up by running:
npm install babel-cli -g

This is not using system linked directories at all from what I can tell. I also tried to run lsof but that locked up too.

@benhillis Can you check npm install on the newer builds to see if it's fixed

@benhillis

This comment has been minimized.

Copy link
Member

commented Feb 8, 2017

@soda0289 - looks like npm install works fine on my internal build with the fix.

@soda0289 soda0289 changed the title Bash lock up when acessing files in system linked directory Bash lock up when reading/writing files Feb 8, 2017

@soda0289

This comment has been minimized.

Copy link
Author

commented Feb 8, 2017

Thanks.

Although using strace will cause the process to complete it can still lock up bash. I see this error before it quits and causes a lock up.

futex(0x3096a08, FUTEX_WAKE_PRIVATE, 1) = 1
futex(0x30969e0, FUTEX_WAKE_PRIVATE, 1) = 1
futex(0x7fa7d4d209d0, FUTEX_WAIT, 181, NULL) = -1 EAGAIN (Resource temporarily unavailable)
brk(0x3152000)                          = 0x3152000
futex(0x19c4cc4, FUTEX_WAKE_OP_PRIVATE, 1, 1, 0x19c4cc0, {FUTEX_OP_SET, 0, FUTEX_OP_CMP_GT, 1}) = 1
futex(0x19c4c80, FUTEX_WAKE_PRIVATE, 1) = 1
futex(0x7fa7d2ce09d0, FUTEX_WAIT, 185, NULL) = -1 EAGAIN (Resource temporarily unavailable)
@Warblefly

This comment has been minimized.

Copy link

commented Feb 9, 2017

So the fix isn't in Build 15031? No problem if not; I'm compiling large suites of programs stably on build 15019 for the time being.

@benhillis

This comment has been minimized.

Copy link
Member

commented Feb 9, 2017

It looks like the fix did not make 15031. We "fast tracked" the change and It will be in the next Insider build.

@rixrix

This comment has been minimized.

Copy link

commented Feb 12, 2017

I'm also experiencing this deadlock, eg. cd /some/directory + tab - FYI

@mstrelan

This comment has been minimized.

Copy link

commented Feb 20, 2017

This sounds like it might fix an issue I'm having. Apache / PHP processes will just hang and sometimes bash will be completely unusable. I believe it is triggered when PHP tries to write to a file, and in my case the file is on a Windows drive. I'm adding this reply in case it helps other people who may be searching for this.

@YvanDaSilva

This comment has been minimized.

Copy link

commented Feb 21, 2017

(15031 build)
@benhillis If you need another repo to test your fixes: git clone https://github.com/jakearchibald/wittr
It is a public / free / repo from "Offline Web Applications" on udacity.
"npm install" will hang on this repo and make bash unresponsive as mentioned on previous posts.

@tjmonsi

This comment has been minimized.

Copy link

commented Feb 27, 2017

is it included in build 15042?

@benhillis

This comment has been minimized.

Copy link
Member

commented Feb 27, 2017

Yes this is resolved in 15042.

@benhillis benhillis closed this Feb 27, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.