[CentOS] Re: Reboots -- lsof and SIGHUP, a combination to know ...

Thu Jun 2 17:50:21 UTC 2005
Bryan J. Smith <b.j.smith@ieee.org> <thebs413 at earthlink.net>

From: Simon Perreault <nomis80 at lqt.ca>
> Sure, theoretically it would be possible, but how would you restart this one?
> [nomis80 at poste10-153 ~]$ sudo lsof | grep libc | grep init
> init          1    root  mem       REG      253,0  1521500     999437 /lib/tls/libc-2.3.5.so

I need to verify the post-install script for the glibc RPM, but
I believe it SIGHUPs the process -- and SIGHUP tells GLibC to
reload itself for all new calls from any new process, while
leaving the old code available for running processes.

Building a tree of service calls and dependencies is the way to
figure out what is using what -- even if indirectly.  lsof does a
fantastic job of this with the right option combinations (I need
to look at my command history).

Remember, UNIX experience is everything, and that means if I don't
know, I get out a test system and throw something like a SIGHUP at
it and see what happens.  ;->

The lack of using UNIX-like signals in NT is what really makes me dislike
NT.  Sure, there are lots of UNIX libraries/services that don't always
handle every signal -- and many just use SIGHUP as a hard restart.  But
many of the critical ones do.  The majority of even Microsoft's own core
libraries are completely ignorant of NT, as they were written for
"Chicago."

Get to know your UNIX/Linux platform.  It's the best way to document
procedures that you may need to have in a situation.  One I regularly
document is how SIGHUP affects different libraries/services.


--
Bryan J. Smith   mailto:b.j.smith at ieee.org