Exit codes & signals · Unix · Docker · curl
What does that exit code mean?
Type an exit status, a signal number, or a name like SIGKILL. ExitCode tells you what
killed the process — 137 is an out-of-memory SIGKILL, 143 is a graceful
SIGTERM, 139 is a segfault — with the cause and the fix.
The process was force-killed and could not clean up.
causeMost often an out-of-memory kill: the Linux OOM killer, or Docker/Kubernetes enforcing a memory limit (shown as OOMKilled). It can also be a manual `kill -9` or an orchestrator escalating after a SIGTERM was ignored.
fixCheck `dmesg` / kernel logs for "Out of memory", and in containers compare usage against the memory limit. Raise the limit or reduce memory use; make sure the app shuts down on SIGTERM so it is never escalated to SIGKILL.
Static lookup, in your browser. Signal numbers are the standard Linux x86-64/ARM values; some differ on other architectures. The exit code alone never replaces reading the program’s own logs.
Unix signals (and the exit code they produce)
A process killed by signal N exits with status 128 + N. These are the
standard Linux x86-64/ARM numbers; SIGUSR1, SIGUSR2 and SIGBUS differ on some architectures.
| Signal | No. | Exit | Default | Meaning |
|---|---|---|---|---|
| SIGHUP | 1 | 129 | Terminate | Hangup — controlling terminal closed or the controlling process died. Often used to tell daemons to reload config. |
| SIGINT | 2 | 130 | Terminate | Interrupt from the keyboard (Ctrl-C). |
| SIGQUIT | 3 | 131 | Core dump | Quit from the keyboard (Ctrl-\); also dumps core. |
| SIGILL | 4 | 132 | Core dump | Illegal instruction — corrupted binary or bad CPU instruction. |
| SIGTRAP | 5 | 133 | Core dump | Trace/breakpoint trap, used by debuggers. |
| SIGABRT | 6 | 134 | Core dump | Abort — from abort(), a failed assertion, glibc heap corruption, or an uncaught C++ exception. |
| SIGBUS | 7 | 135 | Core dump | Bus error — bad memory access, e.g. misaligned access or a truncated mmap. |
| SIGFPE | 8 | 136 | Core dump | Arithmetic exception, e.g. integer divide-by-zero or overflow. |
| SIGKILL | 9 | 137 | Terminate (uncatchable) | Killed immediately; cannot be caught, blocked, or ignored. Sent by `kill -9` and by the Linux OOM killer. |
| SIGUSR1 | 10 | 138 | Terminate | User-defined signal 1 (application-specific). |
| SIGSEGV | 11 | 139 | Core dump | Segmentation fault — invalid memory reference; almost always a bug in native code. |
| SIGUSR2 | 12 | 140 | Terminate | User-defined signal 2 (application-specific). |
| SIGPIPE | 13 | 141 | Terminate | Broken pipe — wrote to a pipe or socket with no reader. |
| SIGALRM | 14 | 142 | Terminate | Timer expired (alarm()). |
| SIGTERM | 15 | 143 | Terminate | Polite termination request — the default of `kill` and the signal orchestrators send to ask a process to shut down. |
| SIGSTKFLT | 16 | 144 | Terminate | Stack fault on coprocessor (rarely used). |
| SIGCHLD | 17 | 145 | Ignore | A child process stopped or terminated. |
| SIGCONT | 18 | 146 | Continue | Continue a process if it was stopped. |
| SIGSTOP | 19 | 147 | Stop (uncatchable) | Stop the process; cannot be caught or ignored. |
| SIGTSTP | 20 | 148 | Stop | Stop typed at the terminal (Ctrl-Z). |
| SIGTTIN | 21 | 149 | Stop | Background process tried to read from the terminal. |
| SIGTTOU | 22 | 150 | Stop | Background process tried to write to the terminal. |
| SIGURG | 23 | 151 | Ignore | Urgent (out-of-band) data on a socket. |
| SIGXCPU | 24 | 152 | Core dump | CPU time limit exceeded (ulimit). |
| SIGXFSZ | 25 | 153 | Core dump | File size limit exceeded (ulimit). |
| SIGVTALRM | 26 | 154 | Terminate | Virtual timer expired. |
| SIGPROF | 27 | 155 | Terminate | Profiling timer expired. |
| SIGWINCH | 28 | 156 | Ignore | Terminal window size changed. |
| SIGIO | 29 | 157 | Terminate | I/O is now possible (SIGPOLL). |
| SIGPWR | 30 | 158 | Terminate | Power failure. |
| SIGSYS | 31 | 159 | Core dump | Bad system call (e.g. blocked by a seccomp filter). |
Common process & shell exit codes
| Code | Meaning |
|---|---|
| 0 | Success. |
| 1 | General / catch-all error. |
| 2 | Shell builtin misuse or a CLI usage error (many tools use 2 for bad arguments). |
| 126 | Command found but not executable (permission denied, or it is a directory). |
| 127 | Command not found — typo or not on PATH. |
| 128 | Invalid argument to exit (valid range is 0-255). |
| 130 | Terminated by SIGINT (128 + 2) — Ctrl-C. |
| 134 | Terminated by SIGABRT (128 + 6) — abort()/assert. |
| 137 | Terminated by SIGKILL (128 + 9) — often an out-of-memory kill. |
| 139 | Terminated by SIGSEGV (128 + 11) — segmentation fault. |
| 143 | Terminated by SIGTERM (128 + 15) — graceful shutdown request. |
| 255 | Exit status out of range (e.g. `exit -1`) or a generic fatal error. |
Common curl exit codes
curl uses its own numbering, unrelated to signals — switch the decoder to the curl tab.
| Code | Name | Meaning |
|---|---|---|
| 1 | UNSUPPORTED_PROTOCOL | Unsupported protocol — this build of curl has no support for it. |
| 2 | FAILED_INIT | Failed to initialize. |
| 3 | URL_MALFORMAT | The URL was malformed. |
| 5 | COULDNT_RESOLVE_PROXY | Couldn't resolve the proxy host. |
| 6 | COULDNT_RESOLVE_HOST | Couldn't resolve the host — DNS failure or a typo in the hostname. |
| 7 | COULDNT_CONNECT | Failed to connect to the host or proxy — wrong port, firewall, or service down. |
| 8 | WEIRD_SERVER_REPLY | The server sent data curl could not parse. |
| 9 | REMOTE_ACCESS_DENIED | Access to the remote resource was denied. |
| 18 | PARTIAL_FILE | The transfer ended early — fewer bytes arrived than expected. |
| 22 | HTTP_RETURNED_ERROR | With -f/--fail, the server returned an HTTP status of 400 or higher. |
| 23 | WRITE_ERROR | Could not write the received data to the local file or disk. |
| 26 | READ_ERROR | Could not read the local file you tried to upload. |
| 27 | OUT_OF_MEMORY | A memory allocation request failed. |
| 28 | OPERATION_TIMEDOUT | The operation timed out (--max-time / --connect-timeout reached). |
| 35 | SSL_CONNECT_ERROR | The TLS/SSL handshake failed — protocol or cipher mismatch. |
| 43 | BAD_FUNCTION_ARGUMENT | Internal error: a function was called with a bad argument. |
| 47 | TOO_MANY_REDIRECTS | Too many redirects (raise with --max-redirs). |
| 51 | PEER_FAILED_VERIFICATION | The server's certificate or fingerprint failed verification. |
| 52 | GOT_NOTHING | The server returned nothing (an empty reply). |
| 55 | SEND_ERROR | Failed sending network data. |
| 56 | RECV_ERROR | Failure receiving network data. |
| 58 | SSL_CERTPROBLEM | Problem with the local client certificate. |
| 60 | PEER_FAILED_VERIFICATION | The CA cert is unknown or the certificate is invalid/expired/self-signed (add --cacert or fix the chain). |
| 61 | BAD_CONTENT_ENCODING | Unrecognized transfer encoding. |
| 63 | FILESIZE_EXCEEDED | Maximum file size exceeded (--max-filesize). |
| 67 | LOGIN_DENIED | The server denied login — wrong username or password. |
| 77 | SSL_CACERT_BADFILE | Problem reading the SSL CA cert. |
| 78 | REMOTE_FILE_NOT_FOUND | The remote file was not found. |
How ExitCode reads a status
- Standard codes: 0 success, 1 generic error, 2 usage/syntax error, 126 not executable, 127 not found, 128 bad exit argument, 255 out of range or fatal.
- Signals: any status of 128 + N means "killed by signal N" — ExitCode subtracts 128 and names the signal (137 -> SIGKILL, 143 -> SIGTERM, 139 -> SIGSEGV).
- Context matters: the Docker/Kubernetes lens adds 125 (docker run failed) and the OOMKilled reading of 137; the curl lens uses curl's own ~30 transfer error codes.
- You can type a number, a signal name (SIGKILL or just "kill"), or an expression like 128+9.
The exit code is a starting point, not a diagnosis. The same number can come from very different
causes, so always confirm against the program’s own logs, dmesg, or your orchestrator’s events.
Questions
What does an exit code above 128 mean?
On Unix, when a process is killed by a signal, its exit status is 128 plus the signal number. So 137 = 128 + 9 = SIGKILL, 143 = 128 + 15 = SIGTERM, 139 = 128 + 11 = SIGSEGV, and 130 = 128 + 2 = SIGINT (Ctrl-C). ExitCode does that subtraction for you and names the signal.
Why does my container exit with 137 (OOMKilled)?
Exit 137 means the process got SIGKILL. In Docker and Kubernetes that is almost always the out-of-memory killer enforcing a memory limit (Kubernetes labels it OOMKilled), or an orchestrator escalating to SIGKILL after a SIGTERM was ignored past the grace period. Compare the container's memory usage against its limit, raise the limit or reduce usage, and make sure the app exits promptly on SIGTERM.
What is the difference between 126 and 127?
127 means the command was not found at all — a typo, a missing package, or it is not on PATH (very common in minimal containers). 126 means the command was found but could not be executed — usually a missing execute bit, a non-executable file, or a bad interpreter line in a script.
Are these signal numbers the same on every system?
The common ones (SIGKILL 9, SIGTERM 15, SIGINT 2, SIGSEGV 11, SIGABRT 6) are the same across Linux and most Unix. A few — SIGUSR1, SIGUSR2, SIGBUS — have different numbers on MIPS, Alpha, and SPARC, and real-time signals occupy 34-64. ExitCode uses the standard Linux x86-64/ARM numbers.
Why does curl use different exit codes?
curl has its own numbering that is unrelated to signals: 6 is "couldn't resolve host", 7 is "couldn't connect", 28 is a timeout, 60 is a TLS certificate problem, and 22 means the server returned an HTTP error of 400+ when you used -f/--fail. Switch the context to "curl" to decode those, since the same number means something completely different there.
Does anything I type get sent anywhere?
No. ExitCode is a static lookup that runs entirely in your browser. There is no backend, no logging, and nothing leaves the page.