edv:os:unix:signale
Signale
In folgender Tabelle sind einige Signale aufgelistet. Das ist die Ausgabe (nicht vollständig) von man 7 signal mit den möglichen Signalen:
Signal | Value | Action | Comment |
---|---|---|---|
SIGHUP | 1 | A | Hangup detected on controlling terminal or death of controlling process |
SIGINT | 2 | A | Interrupt from keyboard |
SIGQUIT | 3 | A | Quit from keyboard |
SIGILL | 4 | A | Illegal Instruction |
SIGABRT | 6 | C | Abort signal from abort(3) |
SIGFPE | 8 | C | Floating point exception |
SIGKILL | 9 | AEF | Kill signal |
SIGSEGV | 11 | C | Invalid memory reference |
SIGPIPE | 13 | A | Broken pipe: write to pipe with no readers |
SIGALRM | 14 | A | Timer signal from alarm(2) |
SIGTERM | 15 | A | Termination signal |
SIGUSR1 | 30,10,16 | A | User-defined signal 1 |
SIGUSR2 | 31,12,17 | A | User-defined signal 2 |
SIGCHLD | 20,17,18 | B | Child stopped or terminated |
SIGCONT | 19,18,25 | Continue if stopped | |
SIGSTOP | 17,19,23 | DEF | Stop process |
SIGTSTP | 18,20,24 | D | Stop typed at tty |
SIGTTIN | 21,21,26 | D | tty input for background process |
SIGTTOU | 22,22,27 | D | tty output for background process |
The letters in the "Action" column have the following meanings:
- A - Default action is to terminate the process.
- B - Default action is to ignore the signal.
- C - Default action is to dump core.
- D - Default action is to stop the process.
- E - Signal cannot be caught.
- F - Signal cannot be ignored.
- G - Not a POSIX.1 conformant signal.
Etwas vollständigere Liste: http://www.yolinux.com/TUTORIALS/C++Signals.html
Um festzustellen, welche Signale auf dem jeweiligen System zur Verfügung stehen:
kill -l
Ausgabe (hier RHEL):
1) SIGHUP 2) SIGINT 3) SIGQUIT 4) SIGILL 5) SIGTRAP 6) SIGABRT 7) SIGBUS 8) SIGFPE 9) SIGKILL 10) SIGUSR1 11) SIGSEGV 12) SIGUSR2 13) SIGPIPE 14) SIGALRM 15) SIGTERM 16) SIGSTKFLT 17) SIGCHLD 18) SIGCONT 19) SIGSTOP 20) SIGTSTP 21) SIGTTIN 22) SIGTTOU 23) SIGURG 24) SIGXCPU 25) SIGXFSZ 26) SIGVTALRM 27) SIGPROF 28) SIGWINCH 29) SIGIO 30) SIGPWR 31) SIGSYS 34) SIGRTMIN 35) SIGRTMIN+1 36) SIGRTMIN+2 37) SIGRTMIN+3 38) SIGRTMIN+4 39) SIGRTMIN+5 40) SIGRTMIN+6 41) SIGRTMIN+7 42) SIGRTMIN+8 43) SIGRTMIN+9 44) SIGRTMIN+10 45) SIGRTMIN+11 46) SIGRTMIN+12 47) SIGRTMIN+13 48) SIGRTMIN+14 49) SIGRTMIN+15 50) SIGRTMAX-14 51) SIGRTMAX-13 52) SIGRTMAX-12 53) SIGRTMAX-11 54) SIGRTMAX-10 55) SIGRTMAX-9 56) SIGRTMAX-8 57) SIGRTMAX-7 58) SIGRTMAX-6 59) SIGRTMAX-5 60) SIGRTMAX-4 61) SIGRTMAX-3 62) SIGRTMAX-2 63) SIGRTMAX-1 64) SIGRTMAX
Hier sind einige Beispiele für die Signalbehandlung in C/C++.
Stand: 04.08.2016
EOF
edv/os/unix/signale.txt · Zuletzt geändert: 2020/01/11 01:23 von 127.0.0.1