]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.bin/killall/killall.1
This commit was generated by cvs2svn to compensate for changes in r58653,
[FreeBSD/FreeBSD.git] / usr.bin / killall / killall.1
1 .\" Copyright (C) 1995 by Joerg Wunsch, Dresden
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS
14 .\" OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
15 .\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
16 .\" DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT,
17 .\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
18 .\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
19 .\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
21 .\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
22 .\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
23 .\" POSSIBILITY OF SUCH DAMAGE.
24 .\"
25 .\" $FreeBSD$
26 .\"
27 .Dd June 25, 1995
28 .Os FreeBSD 2.2 
29 .Dt KILLALL 1
30 .Sh NAME
31 .Nm killall
32 .Nd kill processes by name
33 .Sh SYNOPSIS
34 .Nm killall
35 .Op Fl d \&| Ns Fl v
36 .Op Fl h \&| Ns Fl \&?
37 .Op Fl help
38 .Op Fl l
39 .Op Fl m
40 .Op Fl s
41 .Op Fl SIGNAL
42 .Ar procname ...
43 .Sh DESCRIPTION
44 .Nm Killall
45 kills processes selected by name, as opposed to the selection by pid
46 as done by
47 .Xr kill 1 .
48 By default, it will send a
49 .Dv TERM
50 signal to all processes with an effective UID identical to the
51 caller of
52 .Nm
53 that match the name
54 .Ar procname .
55 The super-user is allowed to kill any process.
56 .Pp
57 The options are as follows:
58 .Bl -tag -width 10n -offset indent
59 .It Fl d \&| Ns Fl v
60 Be more verbose about what will be done.  For a single
61 .Fl d
62 option, a list of the processes that will be sent the signal will be
63 printed, or a message indicating that no matching processes have been
64 found.  If the option
65 .Fl d
66 has been specified at least twice, the effective UID, PID, and name
67 of all processes found in
68 .Xr procfs 5
69 will be listed in addition.
70 .It Fl h \&| Ns Fl \&?
71 .It Fl help
72 Give a help on the command usage and exit.
73 .It Fl l
74 List the names of the available signals and exit, like in
75 .Xr kill 1 .
76 .It Fl m
77 Match the argument
78 .Ar procname
79 as a (case insensitive) regular expression against the names 
80 of processes found in
81 .Xr procfs 5 .
82 CAUTION!  This is dangerous, a single dot will match any process
83 running under the effective UID of the caller.  The regular expression
84 syntax in effect is that used by
85 .Xr perl 1 .
86 .It Fl s
87 Show only what would be done, but do not send any signal.
88 .It Fl SIGNAL
89 Send a different signal instead of the default
90 .Dv TERM .
91 The signal may be specified either as a name
92 .Pq with \&or without a leading Dv SIG ,
93 or numerically.
94 .El
95
96 .Sh ALL PROCESSES
97 Sending a signal to all processes with uid 
98 .Nm XYZ
99 is already supported by
100 .Xr kill 1 . 
101 So use 
102 .Xr kill 1
103 for this job (e.g. $ kill -TERM -1 or
104 as root $ echo kill -TERM -1 | su -m <user>)
105
106
107 .Sh DIAGNOSTICS
108 The
109 .Nm
110 command will respond with a short usage message and exit with a status
111 of 2 in case of a command error.  A status of 1 will be returned if
112 either no matching process has been found or not all processes have
113 been signalled successfully.  Otherwise, a status of 0 will be
114 returned.
115 .Pp
116 Diagnostic messages will only be printed if requested by
117 .Fl d
118 options.
119 .Sh SEE ALSO
120 .Xr kill 1 ,
121 .Xr procfs 5
122 .Sh HISTORY
123 The
124 .Nm
125 command appeared in
126 .Fx 2.1 .
127 It has been modeled after the
128 .Nm
129 command as available on other platforms.
130 .Sh AUTHORS
131 The program has been contributed by
132 .An Wolfram Schneider ,
133 this manual page has been written by
134 .if n Joerg Wunsch.
135 .if t J\(:org Wunsch.