Need to change the recovery options on a windows service (for an added software) from the default "take no action" to "restart service" on at least "first and second occurrence" and probably on "all subsequent" as well.
The timing is not critical as the defaults from the GUI when used in control panel work fine but this is for some people who are not here and should not be allowed to even know that control panel exists.
I almost got there with SC stated as :
"sc failure xxxxx actions=restart/60000/restart/60000// reset=120" but not quite. Windows error-ed "invalid option" but it should work with xxxxx being the service name.
This format also may not set the subsequent failure option to restart as well which is the layout I have tested and found to work best. I am not familiar with using SC and have never configured anything with it before. I also saw some other more complex comands but I only need to set these three options on only this one service.
Thanks
The timing is not critical as the defaults from the GUI when used in control panel work fine but this is for some people who are not here and should not be allowed to even know that control panel exists.

I almost got there with SC stated as :
"sc failure xxxxx actions=restart/60000/restart/60000// reset=120" but not quite. Windows error-ed "invalid option" but it should work with xxxxx being the service name.
This format also may not set the subsequent failure option to restart as well which is the layout I have tested and found to work best. I am not familiar with using SC and have never configured anything with it before. I also saw some other more complex comands but I only need to set these three options on only this one service.
Thanks






