SCOrch – start runbooks from command line

 

To start runbooks from the command line there is a nice little tool which should not be missing in any Orchestrator environment:

SCOJobrunner – it can be donwloaded here , on this technet blogpost you´ll find a description

What you need to start the runbook from cmd is the runbook id. An easy way to get the id by only providing the name is to use this short SQL-Query on your Orchestrator database:

 

Select lower(POLICIES.UniqueID) as RunbookID, lower(CUSTOM_START_PARAMETERS.UniqueID) as ParameterID, CUSTOM_START_PARAMETERS.value
From POLICIES
INNER JOIN OBJECTS  on POLICIES.UniqueID = OBJECTS.ParentID
LEFT OUTER JOIN CUSTOM_START_PARAMETERS on OBJECTS.UniqueID = CUSTOM_START_PARAMETERS.ParentID
Where POLICIES.Name = ‘My Runbook Name’ and policies.deleted = 0

 

You´ll find additional information here

 

So now you could save a running slot for a runbook that is only needed once a week or so by adding a scheduled task that is starting a runbook through SCOJobrunner.

 

Thanks to Markus Klein, John Mattivi and Robert Hearn

Leave a Reply

Your email address will not be published. Required fields are marked *