Orchestrator Runbook "Links"

Ronald Seow 206 Reputation points
2020-08-19T03:02:30.993+00:00

Good morning!

I'm very new to MS Orchestrator so please give me your utmost support whenever possible. Thank you in advance.

I have created a Runbook 18653-sco-image1.png

When the Check User script completed, There's a Published Data $CompareResult which is either "True" or "False". However, in the Link, regardless of how I apply a check, It will always proceed in all directions. Isn't the filter suppose to determine whether the action following the link gets executed?

Appreciate any advise.

Thank you once again and best regards.
Ronald

System Center Orchestrator
System Center Orchestrator
A family of System Center products that provide an automation platform for orchestrating and integrating both Microsoft and non-Microsoft IT tools.
217 questions
0 comments No comments
{count} votes

Accepted answer
  1. Stefan Horz 3,461 Reputation points
    2020-08-21T20:41:08.617+00:00

    Hi Ronald,

    you can download this sample Runbook from here https://1drv.ms/u/s!AkXRVOcQ_Bj_iLR_287BNf_tqL-2-Q?e=XuOhCi.

    19603-checkuserresult.jpg

    Since System Center 2019 Orchestrator the Windows PowerShell Version of the system exectuting the Runbook will be excuted in "Run. Net Script" Activity. For previous versions check https://sc-orchestrator.vasol.eu/run-the-powershell-version-of-windows-executing-the-orchestrator-runbook-service-in-run-net-script-activity/

    A checked-in Runbook will always be executed from the Account running Orchestrator Runbook Service. Only with Runbook Tester a checked-out Runbook will be executed from the user running Tester
    If you want to get Who started the Runbook from the Orchestration console take a look at: https://blog.ctglobalservices.com/automation/jgs/who-started-the-runbook-from-the-orchestration-console-use-this-runbook/.

    Regards
    Stefan

    0 comments No comments

16 additional answers

Sort by: Most helpful
  1. Andreas Baumgarten 98,626 Reputation points MVP
    2020-08-19T09:11:25.81+00:00

    You have to configure the condition shown in the screenshot for "true".
    In the second Link you have to configure the condition for "false" the same way, with the "equals false".

    After everything is done, both links should have only one conditions in each Link.

    Regards
    Andreas

    0 comments No comments

  2. Ronald Seow 206 Reputation points
    2020-08-20T05:38:25.42+00:00

    Hi! Andreas,

    Really appreciate you sparing your precious time to help me.

    I have here images of my test project..

    18985-sco-action-1-initialize-data.jpg19041-sco-smart-link-1.jpg19042-sco-action-2-check-user-details-tab.jpg19043-sco-smart-link-2f.jpg18974-sco-smart-link-2p.jpg19051-sco-action-2-check-user-published-data-tab.jpg19052-sco-action-3-check-user-status-details-tab.jpg19014-sco-action-3-check-user-status-published-data-tab.jpg19004-sco-runbook-test-full-flow.jpg18994-sco-result-screen.jpg

    As you see from the full flow, the tasks are simple;

    1. Get user to input a AD Account
    2. Smart Link 1 - Standard not modified
    3. Validate whether inputted AD Account exist. If no, returns value False, yes returns value True
    4. Smart Link 2F - Check and proceed to next action if False
    5. Smart Link 2P - Check and proceed to next action if True
    6. Validate user account status
    7. Et cetera

    As you see, the Smart Links I have configured only has 1 rule. The result screen does not show the line CompareData as per your example.

    I hope these info will provide you with a clearer picture of what is going on.

    Thanks.
    Ronald

    0 comments No comments

  3. Andreas Baumgarten 98,626 Reputation points MVP
    2020-08-20T10:44:04.187+00:00

    You should verify the value of "CheckStatusResult" in the Runbook Tester.
    If the value of "CheckStatusResult" is "empty" ($null, and not visible in the Runbook Tester output) no condition is met. ($null != true and $null != false). So nothing will happens.
    You can modify the "false" condition to "is not equal True". If the value of "CheckStatusResult" is empty the "false" condition is met and the next activity will start.

    0 comments No comments

  4. Stefan Horz 3,461 Reputation points
    2020-08-20T15:29:17.007+00:00

    Hi,
    is there any reason why you invoke your commands with "powershell {}" inside the "Run .Net Script" Activity? With SC 2019 Orchestrator PowerShell 5 is excuted an the AD module can be used.
    A variable (for example $CheckStatusResult) is not visible if it is set inside "powershell {}".

    Regards,
    Stefan

    0 comments No comments