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

cmd.exe on tmux on WSL freezed #4635

Closed
aont opened this issue Nov 1, 2019 · 3 comments
Closed

cmd.exe on tmux on WSL freezed #4635

aont opened this issue Nov 1, 2019 · 3 comments

Comments

@aont
Copy link

aont commented Nov 1, 2019

Issue Reproduction

cmd.exe on tmux on WSL gets freezed.

I open a tmux session, where cmd.exe is running.

>wsl
$ tmux
$ cmd.exe
>
Ctrl+B D to detach
$ exit

Next, I reopen tmux.

>wsl
$ tmux a
>

I see the previous cmd.exe terminal.
But, any input to cmd.exe is ignored ( though input to tmux is valid for example Ctrl+B & to kill ) .
If this is a bug of tmux, then please let me know. I will post this issue on tmux repos.

Windows: Windows 10 Home 1903 18362.418
Linux: https://lxrunoffline.apphb.com/download/Ubuntu/bionic
tmux: 2.6-3ubuntu0.2

@aont
Copy link
Author

aont commented Nov 1, 2019

Following is the strace output of cmd.exe.

Before exiting WSL

execve("/mnt/c/Windows/system32/cmd.exe", ["cmd.exe"], 0x7fffd991ba88 /* 18 vars */) = 0
arch_prctl(ARCH_SET_FS, 0x293820)       = 0
set_tid_address(0x293858)               = 78
brk(NULL)                               = 0x1cb6000
brk(0x1cb7000)                          = 0x1cb7000
sched_getaffinity(0, 128, [0, 1, 2, 3]) = 64
uname({sysname="Linux", nodename="DESKTOP-IIUBDHU", ...}) = 0
getpid()                                = 78
getcwd("/mnt/c/Users/aont/strace", 4096) = 26
open("/dev/lxss", O_RDWR)               = 3
ioctl(3, _IOC(0, 0, 0x2f, 0x22), 0x7fffddd2ac28) = 0
getcwd("/mnt/c/Users/aont/strace", 4096) = 26
open("/proc/self/mountinfo", O_RDONLY)  = 5
readv(5, [{iov_base="", iov_len=0}, {iov_base="2 2 0:2 / / rw,noatime - wslfs r"..., iov_len=1024}], 2) = 867
readv(5, [{iov_base="", iov_len=0}, {iov_base="", iov_len=1024}], 2) = 0
close(5)                                = 0
getcwd("/mnt/c/Users/aont/strace", 4096) = 26
open("/proc/self/mountinfo", O_RDONLY)  = 5
readv(5, [{iov_base="", iov_len=0}, {iov_base="2 2 0:2 / / rw,noatime - wslfs r"..., iov_len=1024}], 2) = 867
readv(5, [{iov_base="", iov_len=0}, {iov_base="", iov_len=1024}], 2) = 0
close(5)                                = 0
ioctl(0, TCGETS, {B38400 opost isig icanon echo ...}) = 0
ioctl(1, TCGETS, {B38400 opost isig icanon echo ...}) = 0
ioctl(2, TCGETS, {B38400 opost isig icanon echo ...}) = 0
ioctl(0, TIOCGPGRP, [76])               = 0
getpgid(0)                              = 76
fstat(0, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
fstat(2, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
ioctl(0, TIOCGWINSZ, {ws_row=43, ws_col=168, ws_xpixel=0, ws_ypixel=0}) = 0
ioctl(0, SNDCTL_TMR_START or TCSETS, {B38400 -opost -isig -icanon -echo ...}) = 0
dup(0)                                  = 5
ioctl(4, _IOC(0, 0, 0xb7, 0x22), 0x7fffddd2abd8) = 0
ioctl(4, _IOC(0, 0, 0xb7, 0x22), 0x7fffddd2abd8) = 0
ioctl(4, _IOC(0, 0, 0xb7, 0x22), 0x7fffddd2abd8) = 0
write(4, "\0\0\0\0\260\0\0\0005\1\0\0\0\0\0\0006\1\0\0\0\0\0\0007\1\0\0\0\0\0\0"..., 176) = 176
close(0)                                = 0
close(1)                                = 0
close(2)                                = 0
rt_sigprocmask(SIG_BLOCK, [INT WINCH], NULL, 8) = 0
signalfd4(-1, [INT WINCH], 8, 0)        = 0
poll([{fd=4, events=POLLIN}, {fd=0, events=POLLIN}], 2, -1) = 1 ([{fd=4, revents=POLLIN}])
read(4, "\10\0\0\0 \0\0\0\0\0\0\0\0\0\0\0008\1\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 32) = 32
ioctl(4, _IOC(0, 0, 0xa3, 0x22), 0x7fffddd2abf8) = 0
poll([{fd=4, events=POLLIN}, {fd=0, events=POLLIN}], 2, -1) = 1 ([{fd=4, revents=POLLHUP}])

After exiting WSL

poll([{fd=4, events=POLLIN}, {fd=0, events=POLLIN}], 2, -1) = 1 ([{fd=4, revents=POLLHUP}])
poll([{fd=4, events=POLLIN}, {fd=0, events=POLLIN}], 2, -1) = 1 ([{fd=4, revents=POLLHUP}])
poll([{fd=4, events=POLLIN}, {fd=0, events=POLLIN}], 2, -1) = 1 ([{fd=4, revents=POLLHUP}])
... infinite

@benhillis
Copy link
Member

@aont - I cannot reproduce this on 19013.

@aont
Copy link
Author

aont commented Nov 2, 2019

@benhillis - I see. Since I don't use preview release, I cannot confirm. But somehow this is fixed on the next release. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants