[CentOS] Reboots

Thu Jun 2 17:46:20 UTC 2005
Rodrigo Barbosa <rodrigob at suespammers.org>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thu, Jun 02, 2005 at 12:42:47PM -0500, Bryan J. Smith <b.j.smith at ieee.org> wrote:
> From: Rodrigo Barbosa <rodrigob at suespammers.org>
> > That, my friend, is very much true.
> > Depending on the kind of server you are running (mumber of different
> > processes), a reboot will be much easier. Did that myself a few times.
> 
> As far as examining running processes, one should have _good_ operational
> procedures and practices to track what is and isn't running on your system.
> If you can, stick with Sys-V start/kill init scripts for everything, and document
> anything that can't be (as well as why).
> 
> I don't like to rely on reboots to do such things.  In fact, when building a new,
> standard system configuration, I like to shunt to "init 1" and back to "init 3"
> (run-levels assume distro is Fedora-based) several times to ensure that all
> my start/kill init scripts are proper.
> 
> That way I can stop and start user-space services piecemeal and completely. 

Actually, there is another neat trick for rpm based systems.

You see, rpm, prior to removing anything, will rename that to ${NAME}.OLD.
So, libc.so.6 becomes libc.so.6.OLD, and then removed.

As we all know, if that library is currently open by any running process,
it won't be imediately removed (even tho you can't see it with a 'ls').

The trick is pretty simple: lsof | grep OLD

That, of course, only aplies if you are doing everything using RPM
(yum, redhat-update, apt-get).

[]s

- -- 
Rodrigo Barbosa <rodrigob at suespammers.org>
"Quid quid Latine dictum sit, altum viditur"
"Be excellent to each other ..." - Bill & Ted (Wyld Stallyns)

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCn0XspdyWzQ5b5ckRAj9pAJwPyO9S18/ZbY21suAdnmAgxOI2MwCfdrI7
64E1cOFPT2MNhLO/sHLc2p8=
=OC6n
-----END PGP SIGNATURE-----