On 12/06/2015 01:10, post-sysv wrote:
Not sure what you meant by this statement, but you certainly can provided PID1 has set explicit signal handlers.
Then it changed at some point. (I just tested to be sure, and I was able to send a signal to my pid 1 indeed, on Linux 3.19.1.) There was a time where the kernel protected pid 1 against signals sent by user processes, and only sent it signals it generated itself such as SIGINT for Ctrl-Alt-Del. This is the reason why sysvinit uses /dev/initctl as a communication point between init and the "shutdown" program. Of course, POSIX being POSIX, the correct behaviour is completely unspecified and left to the implementation, and Linux being Linux, the change is completely undocumented. -- Laurent
