Christopher Spears wrote: > What is the difference between > > kill 1, SIGNAL > > and > > kill 9, SIGNAL ? > > By reading books and talking to people, I figured out > that kill 1 is the HUP (hang up signal) and kill 9 is > the kill signal. Don't they do the same thing (i.e. > terminate a program)? I was told that kill 1 is a > "nicer" way to end a program than kill 9. > >
HUP is a catchable signal. Meaning the program receives notification that a signal has occurred and which signal. This allows the program to then act in a certain appropriate manner. For example, HUP is often used to restart a server application such as Apache. Generally the server will clear its configuration, re-read its configuration, and then re-perform any startup like stuffs. The KILL (9) signal is not catchable and causes an immediate death without proper cleanup. It is usually reserved for a runaway process that can't be killed with one of the other catchable kill signals like TERM or QUIT. perldoc perlipc For more about signals and their handling in Perl. man -s 7 signal For more about Unix/POSIX signals. http://danconia.org -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>
