System Center 2012 Orchestrator – RunBook Activities

System Center 2012 Orchestrator – RunBook Activities

In this second part of Orchestrator RunBook Concepts series, we’ll cover RunBook activities and its properties.

For the part 1: http://social.technet.microsoft.com/wiki/contents/articles/7982.system-center-2012-orchestrator-runbook-basics.aspx

In the System Center 2012 Orchestrator , activities are the building blocks of RunBooks. In general, individual activities perform three actions:

- Access Published Data.
- Perform some action.
- Publish new data.

By default installation, Orchestrator has following activity collections.

image

Each collection includes custom activities.

image

Other that Orchestrator provides you to extend standard activities with;

  • Integration Packs
  • Orchestrator Integration Toolkit

IP’s are Microsoft or third-party products that contain additional activities for a specific technology. For example Service Manager 2012, Configuration Manager 2012 or HP.

If required functionality is not available in an IP, then you can use OIK to build custom activity. Orchestrator CodepPlex page http://orchestrator.codeplex.com/ includes custom integration packs that was built with OIK.

We’ll cover about how you can import an IP or how you can create your own IP with OIK in the next posts in this series.

Now lets look at the properties of an activity.

GENERAL:

image

General tab allows you to set a custom name and description for each activity.

Published Data:

image

Orchestrator lets you to get data from published data items and convert them into a usable form. For example you can read a text file line by line and publish each line text to the other activities or RunBooks.

image

For the above example, I used Read Line activity to read each line in a text file. Next activity is responsible to start/stop specific services on remote machines.

Now open Start/Stop Services activity details tab;

image

image

By default read line activity publishes above data into the Orchestrator Databus.

In Start/Stop Service activity if you right click any field and click Subscribe, each published data for previously linked activities will be shown up. “Line text” is what I want exactly to get right computer names to start/stop relevant service.

Same process also can be used for .Net Script activity.

image

By default .Net Script activity does not publish any data into the Orchestrator Databus. But you can optionally publish each PowerShell variable with a few clicks.

image

$explorerprocess = Get-Process | where {$_.name -like "iexplore"} | select ID

command gets all processes that name column includes “iexplore” string and then pipe out only ID information. I assigned each ID’s to a variable called $explorerprocess. This is not a useful or well designed script but our purpose is to show how to publish variables within a PowerShell scripts to the Orchestrator Databus.

Now I can define this variable as a Published Data in Run .Net Script activity.

image

Simply give a name and enter your exact variable name. I used same for both field as you see.

image

Now open Append Line Activity details.

image

You can now use previously Published variable.

image

image

If you run your Runbook it will get all Explorer process id’s and append them in to the text file line by line.

image

Of course you can modify your PowerShell script to get better looking outputs.

Published Data Behavior:

This tab contains the properties that determine how the activity handles multi-value Published Data.

image

image

If we would configure Run behavior as “Separate With ,” for the previous example, we would have below output.

image

Security Credentials.

This tab allows you to specify other accounts than RunBook Server Service account. This helps you when activity performs actions on remote computers.

image

Next part we’ll cover how to run or test your RunBooks.

tumblr analytics
Leave a Comment
  • Please add 2 and 2 and type the answer here:
  • Post
Wiki - Revision Comment List(Revision Comment)
Wikis - Comment List
Sort by: Published Date | Most Recent | Most Useful
Posting comments is temporarily disabled until 10:00am PST on Saturday, December 14th. Thank you for your patience.
Comments
  • I am getting an empty window when I select Subcribed > Published Data.  Any idea why I might get that?

  • I'm trying this example in Orchestrator 2012 SP1, the PowerShell running in Run .Net Script activity and the Append line; but the output file is empty. Any thoughts?

Page 1 of 1 (2 items)