Comment 0 for bug 786730

Revision history for this message
Benjamin Kaduk (kaduk-launchpad) wrote : emacs spins when ssh is uncleanly terminated

Binary package hint: emacs23

On several systems that I maintain, we occasionally see user's emacs processes that are using 100% of a CPU, usually when that user is not even logged in. Some follow-up with the users seems to indicate that this can happen when emacs is running in an ssh session, and ssh is terminated uncleanly.

I have been able to reproduce this somewhat-reliably (say, one time in five) by starting emacs, entering M-x shell, running 'yes', and then using the ssh escape ~. to end my session. The emacs process lives, continuing to use CPU (and consume more memory, which is presumably tied to my test case continuing to produce output to an emacs buffer). I have obtained a core file for such a process by attaching to it with gdb and using the 'gcore' command, but my build with DEB_BUILD_OPTIONS=debug does not seem to have preserved debug symbols (I guess I need nostrip as well?), so it's unclear how useful it is. (It's also 700M, due to the aforementioned RAM usage ballooning.)

I looked at the NEWS file for upstream emacs 23.2 and 23.3 and didn't see anything that looked relevant to this issue, so I suspect it's still a problem.

My testing has been done on:
root@caspian:~# uname -a
Linux caspian 2.6.32-25-generic #44-Ubuntu SMP Fri Sep 17 20:05:27 UTC 2010 x86_64 GNU/Linux
root@caspian:~# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 10.04.1 LTS
Release: 10.04
Codename: lucid

And I've been using the source package version 23.1+1-4ubuntu7.2