On Thu, Sep 11, 2008 at 12:38:13PM +0530, devi thapa wrote:
> I have written an ocf script to start and stop a virtual machine.
> I run the script and its working fine.
> I included this script as a resource of heartbeat.
> There is even httpd (lsb script) which is a resource of a
> heartbeat.
> After starting the heartbeat, the heartbeat starts both httpd and
> my ocf script( my script starts the virtual machine)
> When I manually stop both httpd and ocf script(virtual machine is
> stopped), httpd restarts again for a while but my script doesnt
> start(i.e virtual machine doesnt start)
> I have tried many times, but no use. And also there are bugs in my
> script, the logic is working well, if I run the script
> individually.
> 
> what should I do? Is there any configuration problem or script
> must be enhanced.

The first thing you should do is make sure your ocf script works
properly when called by ocf-tester, which is part of the heartbeat
distribution. This basically makes sure your resource agent responds
in a consistent manner that complies with the OCF specifications.

It sounds like your script may not be detecting that the VM is
stopped, so when heartbeat invokes its 'monitor' action it is
returning 'ok' and therefore heartbeat thinks the resource is still
running and doesn't try to restart it.
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems

Reply via email to