Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 03-07-2003, 10:03 AM   #1
LQ Newbie
Registered: Mar 2003
Location: AZ
Distribution: Red Hat 7.2, 7.3, 8.0
Posts: 13

Rep: Reputation: 0
Question Kill a process by command

What is the syntax for killing a command using the command that was run such as (cp)?

kill ???

Old 03-07-2003, 10:08 AM   #2
LQ Guru
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Rep: Reputation: 48
killall whatever

Sometimes this doesn't work, though, in which case it's good to use the process ID number. You can usually find that out by running:

ps ax

There are other related commands for killing processes (sometimes they won't accept the killall command) - but I haven't figured 'em out yet.
Old 03-07-2003, 10:31 AM   #3
Registered: Nov 2002
Location: 50'48''N - 4'21''E
Distribution: SuSE7.1 - SuSE8.1 - SuSE8.2 - RH6.2 - RH7.1 - RH7.3 - RH8.0 - RH9.0 - Fedora Core 1
Posts: 281

Rep: Reputation: 30
Besides, when you've a process running in a window-defined GUI environment, you can use the console and type in : XKILL
Then you'll just have to point and click with your mouse on the window running the process you want to kill.
Old 03-07-2003, 10:49 AM   #4
LQ Newbie
Registered: Mar 2003
Location: AZ
Distribution: Red Hat 7.2, 7.3, 8.0
Posts: 13

Original Poster
Rep: Reputation: 0
No GUI command line only.

Thanks for your input.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
kill D process xrado Linux - General 4 07-04-2005 12:38 PM
cannot kill process (kill -9 does not work) mazer13a Linux - General 1 05-27-2005 02:32 PM
how to kill a process the_rhino Linux - Newbie 5 10-24-2004 10:05 PM
How can I see what process are running and how to I kill them? (command line). brynjarh Linux - Newbie 4 07-07-2004 03:01 PM
one-line kill command using process name julianop Linux - Newbie 6 12-22-2003 11:33 PM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 04:01 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration