Labels

hpunix (63) marathi kavita (52) linux (21) solaris11 (10) AWS (5) numerology (5)

Wednesday, July 9, 2014

Different kill signals in Unix

Different kill signals:

TERM - Terminate - If we want to end a process, we send this signal. It allows the process to clean up nicely though, not like the -9 option (KILL) which just ends everything.

INT - Interrupt - This is a permission which for instance can be used in an NFS environment. If a process hangs, you can interrupt it with say the Ctrl C option.

KILL - exactly what it says. It kills a process without allowing it to clean up, meaning, end all threads, kill child processes etc. It just stops it and can leave either files or other processes in an inconsistent state.

HUP - Hang UP - When we send this signal to say the inetd process, it basically tells inetd to go reread its configuration file as certain changes have been made which you have to incorporate now. The process doesn't actually stop, it just likes stated, rereads its config file. This is true only for daemon processes. For normal application it hangs-up the terminal.

#kill -1  or #kill -HUP
are equivalent.

#kill -2 or #kill -INT
are equivalent.

To make syslogd, re-read its configuration file, send it a HANGUP signal:

            kill -HUP `cat /var/run/syslog.pid`

OR       kill -1 `cat /var/run/syslog.pid`




Thanks...
Kiran Jadhav

**Let's Share our knowledge**

No comments:

Post a Comment