11-11-2019
Some OSes - like AIX - by default do not have a pkill command
Someone might have installed it from somewhere but its not native so do not assume it exists on your host.
If you are logged in as the user med, and you want everything down that this user runs,
kill -9 -1 is a pretty safe method. But only run it when the application stop script left things running. So wait a few min after stopping the app to run the command.
Please note that if you have zombie processes left over (app processes that are owned by 1), this command will still not kill them. Only a system reboot will.
If you have to restart your app often, its better to find out what is preventing your processes from terminating cleanly than to kill those leftover processes.
These 3 Users Gave Thanks to zxmaus For This Post:
10 More Discussions You Might Find Interesting
1. Filesystems, Disks and Memory
Hi all
I've got MacOSX server which is a UNIX based system. I've got 2 partiontion an I like to make just one partition on he disk without loosing any data on part1. Is there a way to do that kind of thing in UNIX or do I have to format everything and put up the system again?
Thanx for reading... (3 Replies)
Discussion started by: gardarm
3 Replies
2. UNIX for Advanced & Expert Users
Hi All,
I am unable to kill a process using kill command. I am using HP-UX system. I have tried with kill -9 and i have root privilages.
How can i terminate this daemon ? ? ?
Regards,
Vijay Hegde (3 Replies)
Discussion started by: VijayHegde
3 Replies
3. Programming
Hi all
i have simple c program , when i wish to kill the app
im using kill(0,-9) , but it seams this command don't do any thing and the program.
just ignore it .
what im doing wrong here ?
im using HP-UX ia64
Thanks (9 Replies)
Discussion started by: umen
9 Replies
4. UNIX for Dummies Questions & Answers
I want to show a output like this
Lee Ballancore
PID TTY TIME CMD
31799 pts/3 00:00:00 vim
31866 pts/3 00:00:00 vim
2495 pts/7 00:00:00 vim
8368 pts/0 00:00:00 vim
9544 pts/2 00:00:00 ps
Alistairr Rutherford
PID TTY TIME CMD
8368 pts/0 00:00:00 vim
9544 pts/2 00:00:00 ps
... (3 Replies)
Discussion started by: nehaquick
3 Replies
5. Shell Programming and Scripting
Sorry, posted the question in other forum. (0 Replies)
Discussion started by: sudhamacs
0 Replies
6. Linux
I want to Kill a process without using kill command as i don't have privileges to kill the process. I know the pid and i am using Linux 2.6.9 OS. (6 Replies)
Discussion started by: sudhamacs
6 Replies
7. Shell Programming and Scripting
Hello Group,
I have a file of data that contain
1
2
3
4
5
I request you help with a shell script for generate all posible combination of these numbers with the following output:
Example:
1 + 2 + 3 + 4 + 5 =
2 + 2 + 3 + 4 + 5 =
3 + 2 + 3 + 4 + 5 =
Thanks in advance.
Carlos (7 Replies)
Discussion started by: csierra
7 Replies
8. Shell Programming and Scripting
Good afternoon
I need to KILL a process in a single command sentence, for example:
kill -9 `ps -aef | grep 'CAL255.4ge' | grep -v grep | awk '{print $2}'`
That sentence Kills the process ID corresponding to the program CAL255.4ge.
However it is possible that the same program... (6 Replies)
Discussion started by: enriquegm82
6 Replies
9. Programming
Is there any program that can create 6 digit numbers with:
(DIGIT_1)+(DIGIT_2)+(DIGIT_3)+(DIGIT_4)+(DIGIT_5)+(DIGIT_6)=10
Any perl or C also can. Anyone can help me? Thank you (6 Replies)
Discussion started by: Tzeronone
6 Replies
10. Shell Programming and Scripting
Hi folks,
I have a numbers from 1-100 and from these nos I have 30 numbers.. From this 30 nos, I have to generate a combination of 6 nos... this 30 numbers will range from 1-100... ( FYI: This is not a lottery game - just kidding) ... I am trying out this in a shell script.. any ideas ? (3 Replies)
Discussion started by: gsiva
3 Replies
LEARN ABOUT REDHAT
killall
KILLALL(1) User Commands KILLALL(1)
NAME
killall - kill processes by name
SYNOPSIS
killall [-e,--exact] [-g,--process-group] [-i,--interactive] [-q,--quiet] [-v,--verbose] [-w,--wait] [-V,--version] [-S,--sid] [-c,--con-
text] [-s,--signal signal] [--] name ...
killall -l
killall -V,--version
DESCRIPTION
killall sends a signal to all processes running any of the specified commands. If no signal name is specified, SIGTERM is sent.
Signals can be specified either by name (e.g. -HUP) or by number (e.g. -1).
If the command name contains a slash (/), processes executing that particular file will be selected for killing, independent of their name.
killall returns a zero return code if at least one process has been killed for each ilisted command. killall returns zero otherwise.
A killall process never kills itself (but may kill other killall processes).
OPTIONS
-e, --exact
Require an exact match for very long names. If a command name is longer than 15 characters, the full name may be unavailable (i.e.
it is swapped out). In this case, killall will kill everything that matches within the first 15 characters. With -e, such entries
are skipped. killall prints a message for each skipped entry if -v is specified in addition to -e,
-g, --process-group
Kill the process group to which the process belongs. The kill signal is only sent once per group, even if multiple processes belong-
ing to the same process group were found.
-i, --interactive
Interactively ask for confirmation before killing.
-l, --list
List all known signal names.
-q, --quiet
Do not complain if no processes were killed.
-v, --verbose
Report if the signal was successfully sent.
-V, --version
Display version information.
-w, --wait
Wait for all killed processes to die. killall checks once per second if any of the killed processes still exist and only returns if
none are left. Note that killall may wait forever if the signal was ignored, had no effect, or if the process stays in zombie
state.
-S (Flask only) Specify SID: kill only processes with given SID. Mutually exclusive with -c argument. Must precede other arguments on
command line.
-c (Flask only) Specify security context: kill only processes with given security context. Mutually exclusive with -s. Must precede
other arguments on the command line.
FILES
/proc location of the proc file system
KNOWN BUGS
Killing by file only works for executables that are kept open during execution, i.e. impure executables can't be killed this way.
Be warned that typing killall name may not have the desired effect on non-Linux systems, especially when done by a privileged user.
killall -w doesn't detect if a process disappears and is replaced by a new process with the same PID between scans.
AUTHORS
Werner Almesberger <Werner.Almesberger@epfl.ch> wrote the original version of psmisc. Since version 20 Craig Small <csmall@small.drop-
bear.id.au> can be blamed.
SEE ALSO
kill(1), fuser(1), pgrep(1), pidof(1), ps(1), kill(2)
Linux March 25, 2001 KILLALL(1)