For the real geeks among us, I started a program yesterday and left it running all night. When I cam in this morning I found that it had used up all available memory (inc. swap) and found that my machine was only just usable. (The program was one I'm writing/debugging! for my PhD).
Anyhow, I hit Ctrl-c in the shell. Nothing happens. I hit Ctrl-\ (SIGQUIT). Nothing happens. Start top. It's still there. kill -9 pid. Still there! In my lecture on Monday I had told the students that kill -9 sends a signal to a process that it cannot catch or ignore. The process has no choice but to die. Here I am on Wednesday morning proving I am a liar. cat /proc/pid/status shows (among other things) that the state is: State: D (disk sleep) According to the proc man page, D is "sleeping in an uninterruptible wait or swapping" Well, since the size of the process was 780MB, and the physical ram is 768MB, my guess is swapping. I do something else for a while. 25 minutes later, the process finally dies. The questions are: 1. What signal killed the process? 2. Why did it take so long? The answer to question 1 is SIGQUIT. No, I didn't expect that either. The partial answer to question 2 is "Because the answer to question 1 is SIGQUIT". SIGQUIT forces a core dump (unless it is caught). My 780MB program dumped core. To an NFS mounted directory. Over 1OMbit ethernet. If what I've said makes sense to you, do you think 25minutes is about right? I think it is rather too long. If most of this post has gone over your head, I'm a bigger geek than you are. Cheers, -- Carl Cerecke, Assistant Lecturer|email: [EMAIL PROTECTED] Department of Computer Science, |Phone: +64 3 364 2987 ext. 7859 University of Canterbury, |Fax: +64 3 364 2569 Private Bag 4800, |http://www.cosc.canterbury.ac.nz/~cdc Christchurch, New Zealand. |
