I need the Windows cluster member to auto run a batch job when the cluster resources are fail over to it from another member.
I use the vbscript below:
The problem is I can't bring it online in cluster administrator, and can't trigger the batch job. It show an error code and I think i miss something in the code.
Set WshShell = CreateObject("WScript.Shell")
RunCommand "c:\start.bat", True
Online = 0
Open = 0
Close = 0
LooksAlive = 0
IsAlive = 0
Function RunCommand(command, wait)
RunCommand = WshShell.Run(command, 1, wait)
Please, Is there anyone can help me !!!