Xymon Mailing List Archive search

hobbit client init script

list T.J. Yang
Fri, 06 Oct 2006 08:24:37 -0500
Message-Id: <user-b651dfce6a00@xymon.invalid>

One way is to modify/enhance hobbit init script to kill  processes own by hobbit after the stop.


In Solaris, ie. kill `ps -u hobbit | grep -v PID|  awk '{print $1}'`


T.J. Yang

From: Gildas Le Nadan <user-231cb1cfd8a8@xymon.invalid>
Reply-To: user-ae9b8668bcde@xymon.invalid
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] hobbit client init script
Date: Fri, 06 Oct 2006 13:40:12 +0100

Henrik Stoerner wrote:
On Fri, Oct 06, 2006 at 01:19:52PM +0100, Gildas Le Nadan wrote:
The way the hobbit init script works (at least on debian), a lot of processes are left running on the host when doing a "/etc/init.d/hobbit-client stop".

Is there any reason for this?
You mean the vmstat processes ?
Yes, but also df commands that seem to be stalled, such as:

ssgtest1a:~# date
Fri Oct  6 13:36:34 BST 2006
ssgtest1a:~# ps aux | grep hobbit
hobbit   21440  0.0  0.0  5620 1188 ?        S    13:06   0:00 /bin/sh /usr/lib/hobbit/client/bin/hobbitclient-linux.sh
hobbit   21456  0.0  0.0  2580  572 ?        S    13:06   0:00 df -Pl -x none -x tmpfs -x shmfs -x unknown -x iso9660
hobbit   21457  0.0  0.0  2624  508 ?        S    13:06   0:00 sed -e /^[^ ?][^ ?]*$/{?N?s/[ ?]*\n[ ?]*/ /?}

The reason is that they run pretty independent of everything else, just
collecting data over a 5 minute period. They will terminate by
themselves after at most 5 minutes; and if you're shutting down the
system, they will get killed.

It's not that it has to be this way, but it was just the easiest way of
doing it.


Regards,
Henrik