Remote shells going rogue

I recently ran across a problem looking very similar to (Erlang/Elixir Interactive Shell jobs get stuck when printing to output) but regrettably it is not easily reproducible.

What we observed (running on OTP 21.1) is that if remote shells are kept connected (but unused) there is the chance that they go into a rogue mode where they start consuming a lot of CPU but without actually doing any work. We’ve traced the problem to the group.erl process which seems to be stuck in an endless loop with driver.erl. The group.erl process is receiving data (https://github.com/erlang/otp/blob/master/lib/kernel/src/group.erl#L666) and the driver is constantly sending empty messages of the form {#PID<0.73.0>, {:data, []}}. The result is that the remote shell process is taking up as much of the CPU as it can with all work spent in the more_data function while it should not be doing anything.

Does any of this sound familiar?

1 Like

I have reported the problem you are referencing on https://bugs.erlang.org and it is probably best place to reach out the Erlang team as it seems like another bug you found :slight_smile:

1 Like

Could you send me the ticket number for this? I did a search earlier and couldn’t find anything related.

1 Like

https://bugs.erlang.org/plugins/servlet/mobile#issue/ERL-472

2 Likes

I may have run into the same thing, but also can’t reliably reproduce. If anyone else can, the new ticket number is:

https://bugs.erlang.org/browse/ERL-891

1 Like