The death touch...

Brian Masinick masinick at yahoo.com
Fri Jul 25 02:25:18 CEST 2003


hugh d fegely wrote:

>Sometimes it works on everything... it all depends on how the program was written -- as Olivier said.. I use xkill first, then if I can't restart (or I know there is a lock file..) I'll go to a console and remove the roadblocks.
>
>
>On Thu, 24 Jul 2003 15:51:29 -0700 (PDT)
>Rich Shepard <rshepard at appl-ecosys.com> wrote:
>
>  
>
>>On Thu, 24 Jul 2003, hugh d fegely wrote:
>>
>>    
>>
>>>the difference as I can figure it is xkill will kill the "window" process
>>>that is displayed on your GUI desktop... it won't necessarily kill the
>>>actual process though..
>>>      
>>>
>>  Thanks, Hugh. I _thought_ that might be the case. Guess I'll stick with my
>>practice of killing processes when necessary.
>>
>>Rich
>>
>>Dr. Richard B. Shepard, President
>>
>>                       Applied Ecosystem Services, Inc. (TM)
>>            2404 SW 22nd Street | Troutdale, OR 97060-1247 | U.S.A.
>> + 1 503-667-4517 (voice) | + 1 503-667-8863 (fax) | rshepard@appl-ecosys.com
>>                         http://www.appl-ecosys.com/
>>    
>>
Just to add a few more thoughts and comments - there are various different levels of things you can do with the kill command.  The default thing is to kill the process using signal 15, the SIGTERM signal.  The SIGKILL signal 9 is  the strongest signal that I know of.  It will kill any process without asking questions.  The only problem you may sometimes run into is if a process has open files or sockets that are waiting on something else, especially with inter process communications, sometimes you can end up with "zombie" processes.

However, kill, at least in some implementations, can take care of this, too.  According to my documentation, it's possible to provide a process name containing the name of a program image.  If you add the -a option, you can kill  processes belonging to others (if you have the privilege to do so).  The killall command, present on some systems, can do stuff like this:

killall mozilla-bin
and get rid of all mozilla related processes in one step.

Here are a list of signals (and their number) that kill supports: 

kill -l
 1) SIGHUP       2) SIGINT       3) SIGQUIT      4) SIGILL
 5) SIGTRAP      6) SIGIOT       7) SIGBUS       8) SIGFPE
 9) SIGKILL     10) SIGUSR1     11) SIGSEGV     12) SIGUSR2
13) SIGPIPE     14) SIGALRM     15) SIGTERM     17) SIGCHLD
18) SIGCONT     19) SIGSTOP     20) SIGTSTP     21) SIGTTIN
22) SIGTTOU     23) SIGURG      24) SIGXCPU     25) SIGXFSZ
26) SIGVTALRM   27) SIGPROF     28) SIGWINCH    29) SIGIO
30) SIGPWR      31) SIGSYS

I think it would be a useful for some of us to add a desktop button that can kill processes.  But Olivier has already indicated that by using the right mouse button click, you can get rid of a process.  Some systems have a nice tool that runs a process monitor, and has the option to not only look at the resource usage of the processes, but also an option to kill or exit the processes.

-- 
Brian Masinick
mailto:masinick at yahoo.com






More information about the Xfce mailing list