On 2010-06-02T14:51:25, Lars Ellenberg <[email protected]> wrote:

> I'd not put it into the RA.
> I'd write a wrapper around whatever process is supposed to run.
> maybe a shell script, or a shell function.
> 
> somthing like that:
> 
> call_crm_resource-F_on_process_exit.sh
> #!/bin/sh
> # takes OCF_RESOURCE_INSTANCE from environment,
> # would need to check that that exists
> "$@"
> crm_resource -F -r $OCF_RESOURCE_INSTANCE

The problem here is if the process either background itself or forks
children that need to be monitored independently. The wrapper will fail
for anything that doesn't remain in the foreground.

(While we're at it, the process watcher could probably also check
whether the pid has gone zombie on us ...)


Regards,
    Lars

-- 
Architect Storage/HA, OPS Engineering, Novell, Inc.
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
"Experience is the name everyone gives to their mistakes." -- Oscar Wilde

_______________________________________________________
Linux-HA-Dev: [email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/

Reply via email to