2

Every so often (about once a month), my vim starts eating resources like crazy, and I'm unable to kill it. Here's an example:

enter image description here

I ran:

kill 13799 

To no effect. I would like to know:

1) Could be vim going haywire due to something else? I use it to write code in and it's usually when the code is running that I get an issue. 2) If not, why would vim do this? 3) How can I kill it? Currently, I have to reboot every time.

Thanks )

Neil
  • 308

1 Answers1

4

kill is quite polite by default, it raises the SIGTERM signal. With this, the application is expected to see and handle the signal (eg quit) but that is completely up to the application to be able and willing.

You can see here that vim is "running" —that's what the R means— and that means it's likely too busy to intercept and process the signal. If it's been doing this a while, you may have stumbled on a bug.

Either which way, if you want to forcibly nuke it, you can use other signals. SIGKILL is a popular choice.

kill -9 13799

It cannot be ignored as it interrupts the current process (with some run-state exceptions, like zombie or other uninterruptible states).

This is an extremely high-level look at this. Take a look at man 7 signal to zoom in.

Oli
  • 299,380