3 ms·
> If pid equals -1, then sig is sent to every process for which the calling process has permission to send signals, except for process 1 (init) Has this behavi
by AdamJacobMuller 7y ago
> If pid equals -1, then sig is sent to every process for which the calling process has permission to send signals, except for process 1 (init)
Has this behavior with init always been this way? I could swear in the past that `kill -9 -1` used to kill init too (and thus cause a reboot), it was one of my favorite "fuck it and reboot" methods.
- pwinnski 7y agoI've used `kill -9 1` to reboot on a single-user system. Perhaps that is what you're remembering?
- AdamJacobMuller 7y agosingle-user when its in like another runlevel?
- aaronmdjones 7y agoLinux will not let you send a signal to init that it has not installed a signal handler for (to avoid unexpected terminate-by-default signals wrecking your machine), and no process can install a signal handler for SIGKILL; ergo, you cannot SIGKILL init. Other operating systems may vary, of course.