Batch script - Check Mirror health
Good morning,
I have another question regarding batch files and Ensemble/Healthshare. Is it possible for a batch file to check the status of the mirror monitor and return it as a status or value?
At present, we store the name of the instance in an echo and reference that. In the event we have to use a different echo, is it possible to have that in a different variable at all?
I hope this makes sense. If I can provide any other information please do let me know.
Kind regards, Alexi Demetriou
Comments
Hi Alexi,
Look at invoking $System.Mirror.GetMemberStatus(). This returns a $List, so you might prefer to craft a routine to run this method and examine the results of the method.
From the Caché bin directory, running 'ccontrol help' will give you assistance for invoking this from a batch script.
If you get stuck, consider the WRC for help.
Erik
Good afternoon Erik,
Thank you for your response, it is nice to hear from you. I have booted up the Ccontrol help, however I am still having some problems marrying the batch file with the code. My previous shutdown script uses different syntax, and when I try to run the commands from within the cache terminal it does not recognise the command. I am definitely going wrong somewhere with my syntax.
I am also using the following as a reference:
https://docs.intersystems.com/latest/csp/documatic/%25CSP.Documatic.cls…
Is there a different guide on how best to go about this programming at all?
Many thanks and kind regards, Alexi Demetriou