PowerShell Notifier

Use the Powershell notifier to execute a PowerShell script when a device meets specified conditions.

Note: Before you can run a PowerShell Notifier, you must configure PowerShell to work with InterMapper(Pg 1) on the local machine and any target machines you want to access with PowerShell. Use PowerShell probes to test the connectivity.

To configure a PowerShell notifier:

  1. Enter a notifier Name.
  2. From the Notifier Type dropdown menu, choose PowerShell. The PowerShell Notifier configuration window appears as shown below.
  3. Choose whether you want to execute the script on the local machine (localhost) or a remote machine.
  4. In the PowerShell arguments box, enter the arguments you want to use define how the PowerShell process executes. See below for more information.
  5. In the PowerShell command text box, enter the command you want to execute. See below for more information.

PowerShell Notifier Settings

Notes:

Available Variables

You can use many InterMapper variables, including ${address}, ${User}, ${Password*}, as well as any of the other information available to Command-Line notifiers.

Choosing an Execution Method

Three methods of execution are available. Each one determines how the script will be executed, and what device it is executed on.

Default Command Text

When you choose an execution method, the PowerShell command text box is preloaded an appropriate command.

Here are the defaults for each execution method:

./MyPowerShellNotifier.ps1 "${MESSAGE}"
Invoke-Command -FilePath ./MyPowerShellNotifier.ps1 -ArgumentList "${MESSAGE}"
Invoke-Command -FilePath ./MyPowerShellNotifier.ps1 -ArgumentList "${MESSAGE}"

Change the name of the .ps1 script and change or add parameters as needed.

Execution: Local Device

The specified command text is executed on the local machine.

Execution: Alerting Device

The specified command text is executed on the machine that triggered the alert.

Execution: Other Device

The specified command text is executed on the machine specified in the ComputerName box.