question

jansiranikrishnan-1796 avatar image
0 Votes"
jansiranikrishnan-1796 asked AnnaManzoni-2374 commented

Creating Runbooks

Hi Team,

I have a requirement to create two runbooks in SCORCH (System Center Orchestrator) as follows.

  1. Whenever a new incident is created or any existing incident modified (based on the event) in SCSM, I have to fetch the information (Example: Title, Description, Impact, urgency, Priority, Affected User etc) from the incident and send this to the ServiceNow (I am working on an assignment to integrate SCSM ITIL with ServiceNow).

  2. At ServiceNow, this incident information will be replicated and worked upon by some technical experts and if they update anything on this incident, this should get replicated in ITSSP. So, I have to receive the updates from the ServiceNow and update the required fields in ITSSP/SCSM.

If i create these two runbooks, I will get the API link as follows. So, i can share this API link to the ServiceNow team as the endpoint URL.
http://orchestratorservername:81/orchestrator2012/orchestrator.svc/runbooks

Please throw some light on how to proceed to create the two runbooks. This would be of a great help.

Thanking you,

Regards,
Jansi

msc-service-managermsc-orchestrator
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Maybe this will be a piece of help for your problem:

Get a Runbook
PowerShell

 $secpasswd = ConvertTo-SecureString "Password01!" -AsPlainText -Force
 $mycreds = New-Object System.Management.Automation.PSCredential("contoso\Administrator", $secpasswd)
 $OrchURI = "http://SCO01:81/Orchestrator2012/Orchestrator.svc/Runbooks?`$filter=Name eq 'Test'"
 $ResponseObject = invoke-webrequest -Uri $OrchURI -method Get -Credential $mycreds
 $ResponseObject.Content

The runbook isn’t impressive or complex and does not follow the ITIL guidelines. The workflow will take the input variable… add some text to it… and store it as a variable. That variable will be then returned by a completed runbook.


0 Votes 0 ·

1 Answer

AndreasBaumgarten avatar image
0 Votes"
AndreasBaumgarten answered AndreasBaumgarten commented

Hi @jansiranikrishnan-1796 ,

1) You can use the Monitor Object activity from the SCSM Integration Pack.
With this activity you can monitor created or updated objects in SCSM.

2) Here you can find the SCORCH Job Runner or SCORCH Webservice PowerShell Examples
https://archive.codeplex.com/?p=orchestrator
This way you can trigger SCORCH Runbooks from remote


(If the reply was helpful please don't forget to upvote and/or accept as answer, thank you)

Regards
Andreas Baumgarten

· 4
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi Andreas,

Thank you for mentioning the "Monitor Object" activity to get notified on the newly created or updated objects in SCSM. But the link for the SCORCH webservices powershell examples does not contain much required information. Please let me know in case you have any idea of creating the required runbooks.

Regards,
Jansi

0 Votes 0 ·

Maybe this helps:
https://techcommunity.microsoft.com/t5/system-center-blog/cool-tool-new-command-line-utility-to-start-a-runbook/ba-p/345890

With the ScoJobRunner,exe it's possible to start a Runbook in Orchestrator.
With the -Parameters you can start a Runbook job with parameters. For instance with the WorkItem Id. Inside the Runbook you could use these parameters to update an existing Incident Object in SCSM.

For using the Orchestrator Web Service this might be helpful:
http://www.wendicai.net/?p=157
http://www.laurierhodes.info/?q=node/101


(If the reply was helpful please don't forget to upvote and/or accept as answer, thank you)

Regards
Andreas Baumgarten


0 Votes 0 ·

Hi Andreas,


You are just awesome. I just had a glance on the links which you have provided. I hope this will definitely help me in implementing the requirement. I will have a detailed view tomorrow and see the feasible options to adapt.

Thanking you for your time and effort :)
-Jansi

0 Votes 0 ·
Show more comments