autobuild ctdb cleanup

Amitay Isaacs amitay at gmail.com
Fri Jul 4 01:23:23 MDT 2014


On Thu, Jul 3, 2014 at 9:08 AM, Stefan (metze) Metzmacher <metze at samba.org>
wrote:

> Hi Amitay,
>
> I noticed that there's a lot of ctdb and ctdb_reco processes
> left after an autobuild (maybe only failed once).
>
> Could you take a look at that and may implement something like
> the smbd_stdin_handler in source3/smbd/server.c.
> So that ctdb can be started in foreground and exit when the parent went
> away.
>
> Thanks!
> metze
>
>
Hi metze,

There is already logic in ctdb to clean up child processes if the main
daemon goes away.  The problem here is of shutting down the local ctdb
daemons when autobuild.py terminates abnormally.

Here's a patch that shuts down the local daemons started for test if the
run_tests.sh script is sent SIGINT or SIGTERM.  I have tested it by running
autobuild.py and then pressing Ctrl-C. This sends SIGTERM to run_tests.sh
and shuts down the local daemons.  So as long as autobuild.py terminates
the child processes, this would work.

Amitay.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-ctdb-tests-Shutdown-local-daemons-if-the-tests-exit-.patch
Type: text/x-patch
Size: 1493 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20140704/cefd2cd7/attachment.bin>


More information about the samba-technical mailing list