SYNOPSIS

       skill [-signal] [-afinvw] {tty user command pid}
       snice [(-|+)priority] [-afinvw] {tty user command pid}
       skill -l


DESCRIPTION

       Skill  sends  the  terminate signal to a set of processes.  If a signal
       name (or number) preceded by a `-' is given, that signal will  be  sub-
       stituted  for  terminate.   The  command  `skill -l' displays a list of
       available signals.

       Snice  alters  the  scheduling  priority  of  selected  processes.   By
       default,  the  new priority is +4, but an argument of the form `+N' (or
       `-N') can be used to specify some other value.  Since  the  meaning  of
       "priority" differs wildly, snice will normalize priorities to the range
       PRIO_MIN through PRIO_MAX; generally `-20' is the highest priority  and
       `+20'  is  the  (s)lowest.   Apart  from the super-user, users may only
       increment their priority.  An invalid priority is quietly rounded up or
       down  to the first acceptable value.  Where multiple scheduling classes
       are available, snice is only guaranteed to operate on processes in  the
       "Time Share" class.

       Options accepted by both commands are as follows:

       -a     When run by an unprivileged user, processes that belong to other
              users are quietly ignored.  In all mode, this internal filter is
              disabled.   It  may be used in conjunction with the `-n' flag to
              display a set of processes  that  match  a  specified  criteria.
              This flag has no effect for the super-user.

       -f     In fast mode, the machine-dependent code responsible for reading
              processes is allowed to make decisions to improve speed  at  the
              expense of error reporting (e.g. commands may not be displayed).
              This option mainly exists to aid in killing runaway processes on
              operating systems with complicated virtual memory designs.

       -i     In interactive mode, the user is prompted with each process that
              is a candidate for action.  Responding `y' will  carry  out  the
              stated  action.  Also, a ^D at this prompt causes skill or snice
              to exit immediately.

       -n     Display process id's but do not act on them.

       -v     In verbose mode, the id of each process successfully acted  upon
              is displayed.  Verbose mode may be enabled by default by setting
              the "SKILL_VERBOSE" environment variable.
              Alternately, when this is the only argument, version information
              is displayed and the program exits.

       -w     Display warning messages for unreachable processes.

       All  command  line  arguments  are  order independent.  Skill and snice
       that they will do so incorrectly (e.g. a system command is also a  user
       name).  Both programs try to match an argument with a tty, a user name,
       and a process id, before classifying it  as  a  command.   To  override
       this,  an  argument  can be forced to a particular type by preceding it
       with `-c' (command), `-u' (user), `-t' (tty), or `-p' (process id).  As
       a special case, a question mark (`?') is categorized as a tty, and will
       match processes without controlling ttys.

       When targeting processes by command name, both skill and snice use  the
       actual  name of the binary (i.e. that which is used for accounting pur-
       poses).  Otherwise, as processes are permitted to change their argument
       vector  (specifically  argv[0]),  an  errant  program could continually
       change its name to avoid being acted upon.  When  targeting  a  process
       that  has  changed  its  name,  use the `-nv' options to see its actual
       name.  Command names may be  specified  using  regular  expressions  by
       enclosing  them  in  forward  slashes.  For example, `skill -KILL /d$/'
       will send the kill signal to processes with names ending in "d".

       Process id's are not known beforehand, so both kernel  memory  and  the
       swap  device  must  be  searched  for the required information.  Alter-
       nately, on some systems, the "/proc" file system is examined.   When  a
       process  fitting  each  category is discovered, it is immediately acted
       upon (unless running in interactive or display-only  mode).   Processes
       must  belong  to  the  current user unless said user is the super-user.
       Neither program will ever act on itself, but everything  else  is  fair
       game.

       Exit  status is normally 0; if the user makes a mistake, 1 is returned.
       If a system error occurs, exit status is 2.


FILES

       /vmunix        system name list
       /dev/mem       physical memory
       /dev/kmem      kernel virtual memory
       /dev/drum      swap device
       /proc          process file system
       /dev           searched to map ttys into device numbers


SEE ALSO

       kill(1), nice(1), priocntl(1), renice(1), ps(1),
       kill(2), setpriority(2), signal(2), regex(3), proc(4)


AUTHOR

       Jeff Forys


CONTRIBUTORS

       David Sharnoff      Greg Earle          Christos Zoulas
       Gorodecki Tom       Mike Hibler         Ric Anderson
       Chuck L Blake       Lee Duncan          Allan E Johannesen
       Michael Smith       Aaron Denney        Simon Burge


BUGS

4th Berkeley Distribution        April 6, 2005                        SKILL(1)

Man(1) output converted with man2html