#1076380 screen: hangs for ~10 seconds when creating tab with zsh+unlimit

Package:
screen
Source:
screen
Description:
terminal multiplexer with VT100/ANSI terminal emulation
Submitter:
Linus Lüssing
Date:
2026-05-21 20:03:01 UTC
Severity:
normal
Tags:
#1076380#5
Date:
2024-07-15 12:13:26 UTC
From:
To:
Dear Maintainer,

Since an "apt-get update && apt-get dist-upgrade" on Debian Sid about
one or two months ago starting GNU screen or any new tab within hangs
for about 10-15 seconds. During that time the SCREEN process is seen
with 100% CPU usage in htop.

I could narrow the issue down to the "unlimit" line at the very start of
my ~/.zshrc. I think I had added this one (plus "limit stack 8192" and
"limit core 0" a long time ago to enable coredumps of crashing
processes with systemd-coredump / coredumpctl. However this issue only
appeared after the update in the last one or two months.

Removing the "unlimit" line from my ~/.zshrc fixes the problem.
The following line should be sufficient to reproduce the problem, too:

  $ zsh -c "unlimit; screen"

I also ran "perf record -g -F 99 -- timeout 10 screen" to create a
~/perf.data file of the hang and then ran
"perf report -n --stdio > ~/perf.data-report.txt", as well and created a
FlameGraph SVG [0]. See attachments (SVG is interactive in a browser).

However, even though I had screen-dbgsym installed, I don't quite
understand what in GNU screen is calling (looping around?) __poll(),
which seems to create the main busyness, seems like there is a
missing symbol for that.

This is on a recent Debian Sid, with Linux 6.9.8-amd64 / 6.9.8-1.

Regards, Linus

[0]: https://brendangregg.com/FlameGraphs/cpuflamegraphs.html


*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?
   * What exactly did you do (or not do) that was effective (or
     ineffective)?
   * What was the outcome of this action?
   * What outcome did you expect instead?

*** End of the template - remove these template lines ***

#1076380#10
Date:
2024-07-15 12:38:41 UTC
From:
To:
Attaching an strace as well, created via:

  $ zsh -c "unlimit; strace screen 2> /tmp/screen-strace.txt"

It keeps busy looping around a poll().

#1076380#15
Date:
2025-05-04 14:40:05 UTC
From:
To:
I ran into the same issue and to me it looks like upstream bug about a large
RLIMIT_NOFILE https://savannah.gnu.org/bugs/?55618

indeed, e.g. ulimit -n 8192 worked for me to get screen to work

#1076380#20
Date:
2026-05-21 20:01:38 UTC
From:
To:
Hi folks,

Please re-test this with the latest unstable upload (5.0.1-2) and verify
this bug still exists.

Thanks,
Peter Dey