PowerShell Remoting Insanity with AppAssure and the Invoke-Command Cmdlet

Although simple, I thought I would share the following PowerShell script since it’s neat due to the fact that it uses the PowerShell remoting Invoke-Command cmdlet to retrieve a list of server names that are protected by an AppAssure Core server where the status is not protected, then it uses the output of that portion of the script (Nesting in parenthesis) as the input for the ComputerName parameter of the outer portion of the script which uses another Invoke-Command to attempt to start the AppAssureAgent service on those servers that were returned by the nested portion of the script:

appassure-icm

AppAssure version 5.3.1 or higher is required on the AppAssure Core server for PowerShell support. I’ve used the simplified PowerShell version 3 Where-Object syntax in this script since the AppAssure Core server is running PowerShell version 3 .

µ

About Mike F Robbins

PowerShell Enthusiast | IT Pro | Winner of the Advanced Category in the 2013 PowerShell Scripting Games | Author of Chapter 6 in the PowerShell Deep Dives Book.
This entry was posted in AppAssure, PowerShell and tagged , . Bookmark the permalink.

2 Responses to PowerShell Remoting Insanity with AppAssure and the Invoke-Command Cmdlet

  1. Andy C says:

    I found this very awesome. Is there anyway you could make more full plug-and-play scripts for 5.3.1? I have put down my contact e-mail for further discussion. I love Powershell.

  2. Robin says:

    Been trying to write a script that archives the back up of to local disk after each snap ,

    Only snapping once a day and want to export it to a USB hard drive ,

    Do you have any advice on how to script this ?

Leave a Reply