-
-
Notifications
You must be signed in to change notification settings - Fork 651
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
Crash when exiting shell on single CPU systems #882
Comments
Yeee-ha! Here is how you disable all CPU cores but one in Linux at runtime: After that, try the reproducer in my first post. Cores can be enabled again with |
Since this bug is depending on a race condition, I managed to reproduce even on multi-CPU systems:
Please note that I tried this on a pretty slow Intel Atom CPU, so it might not trigger on faster systems. I just want to raise awareness that there are currently at least two crashes due to race conditions based around the terminal file descriptor handling. Two because I got two different error messages (the one from first post and the one below).
|
Quick and dirty bandaid fix to some server crashes which occur to me lately. The underlying issue seems to be a race condition somewhere when the shell in the pane exits and the tty file descriptor becomes invalid, but zellij wants to write/read it? Bug trigger: - open some panes - exit the shells in the panes by spamming Ctrl-D works best when the system only runs on a single CPU, run the following to disable all cores but one: echo 0 | sudo tee /sys/devices/system/cpu/cpu*/online
Cool, can easily reproduce it with these steps. (super weird to go from 16 cores to 1 btw 😄) |
Basic information
zellij --version
: 0.21.0 / 0.20.1 (crash happens with both)uname -av
: Linux skydragon 5.15.2-arch1-1 #1 SMP PREEMPT Fri, 12 Nov 2021 19:22:10 +0000 x86_64 GNU/LinuxFurther information
This only happens on my vserver, I cannot reproduce locally. Happens via ssh oder tty accessed via hoster's VNC feature.
This is a fairly slow CPU server, and I had already problems with earlier zellij builds there, but I don't know anymore.
The issue seems this exact machine.
Reproduction steps:
zellij
Ctrl-D
or typeexit
to quit the shellBacktrace for debug build of the tree at the commit 639566d:
Click to expand:
The text was updated successfully, but these errors were encountered: