How Are Signals Represented?
In UNIX, every type of event that can occur is represented by a separate signal. Every signal is a small positive integer. The signals most commonly encountered in shell script programming are given in Table 19.1. The signals are available on all versions of UNIX.
Name | Value | Description |
---|---|---|
SIGHUP | 1 | Hangup detected on controlling terminal or death of controlling process |
SIGINT | 2 | Interrupt from keyboard |
SIGQUIT | 3 | Quit from keyboard |
SIGKILL | 9 | Kill signal |
SIGALRM | 14 | Alarm Clock signal (used for timers) |
SIGTERM | 15 | Termination signal |
In addition to the signals listed in Table 19.1, you might see a reference to signal 0. This signal is more of a shell convention than a real signal. ...
Get Sams Teach Yourself Shell Programming in 24 Hours, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.