SIGKILL
Encyclopedia
On POSIX
-compliant platforms, SIGKILL is the signal
sent to a process
to cause it to terminate immediately. The symbolic constant
for SIGKILL is defined in the header file
terminate immediately.
and SIGINT
, this signal cannot be caught or ignored, and the receiving process cannot perform any clean-up upon receiving this signal.
POSIX
POSIX , an acronym for "Portable Operating System Interface", is a family of standards specified by the IEEE for maintaining compatibility between operating systems...
-compliant platforms, SIGKILL is the signal
Signal (computing)
A signal is a limited form of inter-process communication used in Unix, Unix-like, and other POSIX-compliant operating systems. Essentially it is an asynchronous notification sent to a process in order to notify it of an event that occurred. When a signal is sent to a process, the operating system...
sent to a process
Process (computing)
In computing, a process is an instance of a computer program that is being executed. It contains the program code and its current activity. Depending on the operating system , a process may be made up of multiple threads of execution that execute instructions concurrently.A computer program is a...
to cause it to terminate immediately. The symbolic constant
C preprocessor
The C preprocessor is the preprocessor for the C and C++ computer programming languages. The preprocessor handles directives for source file inclusion , macro definitions , and conditional inclusion ....
for SIGKILL is defined in the header file
Header file
Some programming languages use header files. These files allow programmers to separate certain elements of a program's source code into reusable files. Header files commonly contain forward declarations of classes, subroutines, variables, and other identifiers...
signal.hSignal.hsignal.h is a header file defined in the C Standard Library to specify how a program handles signals while it executes. A signal can report some exceptional behavior within the program , or a signal can report some asynchronous event outside the program .A signal can be generated...
. Symbolic signal names are used because signal numbers can vary across platforms, however on the vast majority of systems, SIGKILL is signal #9.Etymology
SIG is a common prefix for signal names. KILL is computer jargon for the action of making a processProcess (computing)
In computing, a process is an instance of a computer program that is being executed. It contains the program code and its current activity. Depending on the operating system , a process may be made up of multiple threads of execution that execute instructions concurrently.A computer program is a...
terminate immediately.
Usage
When sent to a program, SIGKILL causes it to terminate immediately. In contrast to SIGTERMSIGTERM
On POSIX-compliant platforms, SIGTERM is the signal sent to a process to request its termination. The symbolic constant for SIGTERM is defined in the header file signal.h. Symbolic signal names are used because signal numbers can vary across platforms, however on the vast majority of systems,...
and SIGINT
SIGINT (POSIX)
On POSIX-compliant platforms, SIGINT is the signal sent to a process by its controlling terminal when a user wishes to interrupt the process. In source code, SIGINT is a symbolic constant defined in the header file signal.h...
, this signal cannot be caught or ignored, and the receiving process cannot perform any clean-up upon receiving this signal.
- Zombie processZombie processOn Unix and Unix-like computer operating systems, a zombie process or defunct process is a process that has completed execution but still has an entry in the process table. This entry is still needed to allow the process that started the process to read its exit status. The term zombie process...
es cannot be killed since they are already dead and waiting for their parent processes to reap them. - Processes that are in the blocked state will not die until they wake up again.
- The initInitinit is a program for Unix-based computer operating systems that spawns all other processes. It runs as a daemon and typically has PID 1. The boot loader starts the kernel and the kernel starts init...
process is special: It does not get signals that it does not want to handle, and thus it can ignore SIGKILL. - Because SIGKILL gives the process no opportunity to do cleanup operations on terminating, in most system shutdown procedures an attempt is first made to terminate processes using SIGTERM, before resorting to SIGKILL.
- To speed the computer shutdown procedure, Mac OS X 10.6, aka Snow LeopardMac OS X v10.6Mac OS X Snow Leopard is the seventh major release of Mac OS X, Apple's desktop and server operating system for Macintosh computers.Snow Leopard was publicly unveiled on June 8, 2009 at the Apple Worldwide Developers Conference...
, will send SIGKILL to applications that have marked themselves "clean" resulting in faster shutdown times with, presumably, no ill effects. - An uninterruptibly sleeping process may not terminate (and free its resources) even when sent SIGKILL. This is one of the few cases in which a UNIX system may have to be rebooted to solve a temporary software problem.