System Center Orchestrator: Runbook Shows ‘Running’ in Designer But Pending State in Console

Ok, so complicated title but what I’m describing here is that the runbook is triggered from the Service Manager Self-Service Portal and shows that it’s running with no entry under the log portion of the runbook designer, and it may or may not show that it’s in pending state in the Orchestration Console. Here’s a visual of what I’m talking about:

Thankfully, this is an easy fix. Check your inputs from the Service Manager Self-Service Portal, if you entered &, <, or >, Orchestrator interprets what you’ve entered as a command and freezes execution. You simply can’t use these characters in your Service Manager Self-Service Portal inputs. So remove these, replace them with other character(s) and the problem will go away.

Until next time!

830 total views, no views today

System Center Orchestrator 2016: Error When Changing the Data Source After Update Rollup 4 Installation

Hello again!

I came across an interesting issue this week while applying System Center 2016 Update Rollup 4 to my company’s System Center Orchestrator instance. After the install, you are required to re-associate the Orchestrator database with the Orchestrator instance by using the ‘Data Store Configuration’ tool found in the management service’s installation folder. In my case, I would type in the name of my SQL Server instance and on the second page when trying to select the Orchestrator database, I would receive a BLANK error. That’s it, no information presented to me or input to any log file that I could find.

I was planning on reinstalling everything, as I have my runbooks backed up every night, when I had an idea: my Orchestrator server does not have SQL Server installed, and since I was trying to reach out to a SQL Server instance, it made sense to me that I may be missing required files in order to make this tool work. So, before I went through the process of reinstalling everything, I downloaded and installed SQL Server 2014 Express edition to the Orchestrator management server. After the install, I went back to the ‘Data Store Configuration’ tool and…IT WORKED!!!

So, long story short… if you are having issues with the ‘Data Store Configuration’ tool provided with System Center Orchestrator, try installing an Express version of SQL Server (or really any modern version of SQL Server would likely work) to install any missing dependencies that are not documented.

Until next time!

1,039 total views, no views today

Missing expression after unary operator ‘-‘

Worked through this error the other day. Received this error when trying to use the back-tick character for multi-line commands in PowerShell. The good news is that it’s easy to fix. My issue was that I had a space character after the back-tick that was apparently interfering with command execution. Simply remove this space and the code will execute as expected.

Until next time,

1,300 total views, no views today

LM Hosts Lookup DSC PowerShell Module Available for Download

My new PowerShell DSC module for LMHosts Lookup is available on the PowerShell Gallery. It toggles the LMHosts Lookup option found in the advanced section of your network adapter properties.

You can get it by running Install-Module in PowerShell 5+ or at this link

As always, feel free to post your feedback on this and all my code that I post!


1,730 total views, no views today

WINS Client PowerShell DSC Module Available for Download

Just wanted to drop a quick note that you can get my new PowerShell DSC module from the PowerShell Gallery. It configures the WINS client on Windows computers to point to the address you provide.

You can get it by running Install-Module in PowerShell 5+ or at this link


480 total views, no views today

PowerShell – Running a Program Remotely With Arguments

I was having trouble with getting a certain program to run remotely from a PowerShell script, I just couldn’t get it to run using Start-Process, Invoke-Command, or using the old WMI create method. Each of them was giving me its own headache, and it seemed like I could sort of get one to work, but each time I got a part working another fell apart. I was able to get the program running locally using Start-Process, so I decided that this was going to be my savior but I needed to get it running remotely.

I ended up using a combination of Invoke-Command and Start-Process to do the job. But this has its own ‘gotchas’ (I hate that word) that need to be taken in to account. Invoke-Command requires you to pass some form of a script block, and local variables don’t work inside of it. I tried a couple of ways of getting those working, including declaring them in the script block itself. This kind of worked, but I couldn’t turn it in to a function easily. Finally I caught this post:

This pointed me to the magic of $args. Basically your local variables can be bound to the $args variable and easily passed to your script block.

Anyway, here’s the code of my working script block:

$PSSession = New-PSSession -ComputerName $Server
Invoke-Command -Session $PSSession -ScriptBlock {
$param1 = $args[0]
$param2 = $args[1]
$Client = $param1 + "_" + $param2

$Arguments = @"
-PublishItem -a "$Client" -ItemPath "D:\$param1\$param2\executable1.EXE" -StartDirectory "D:\$param1\$param2\" -r "/option"
Start-Process -FilePath "C:\Program Files\Some Company\Programs\executable2.exe" -ArgumentList $Arguments
}$args "Test", "defiantOwl"

All you need to do is to put $args with an index value when instantiating your variable in the script block, then pass these variables (separated by commas) at the end of your script block.

As always, please leave a comment if you have a question and I’ll do my best to respond.


509 total views, no views today