After migrating PA Server Monitor from Windows Server 2008R2 Windows Server 2012R2, Powershell scripts no longer work. I actually get the same error if I press Test Script when the script editor is empty.

I found this post, but it did not help - http://support.poweradmin.com/osqa/questions/578/execute-script-action-powershell-script

Powershell scripts run successfully from the command line.

alt text

Thanks Gary.

asked 30 Aug '15, 20:12

lynodch's gravatar image

lynodch
1111
accept rate: 0%


Hi lynodch,

have you tried switching the monitor to use PowerShell v4? In the latest version you can switch for v2 to v4. Windows Server 2012 doesn't come with PowerShell v2 installed, this could be the issue.

Thanks
Quinn

Please make sure to mark your questions accepted when you have your answer by clicking the gray check mark to the left of the answer.

link

answered 31 Aug '15, 11:46

Quinn's gravatar image

Quinn ♦♦
14.5k3925
accept rate: 35%

Hello,

I've checked all the settings but found nothing. Where can I switch V2 to V4?

Thanks Gary.

link

answered 31 Aug '15, 20:26

lynodch's gravatar image

lynodch
1111
accept rate: 0%

Gary,

The setting to change from v2 to v4 is set at the monitor level. Go the server that has your Execute Script monitor and select the monitor. Right above the text box where you entered your code you will see dropdown box labeled "Script Language:", one of the options in this dropdown is PowerShell v4.

Thanks
Quinn

Please make sure to mark your questions accepted when you have your answer by clicking the gray check mark to the left of the answer.

link

answered 01 Sep '15, 08:43

Quinn's gravatar image

Quinn ♦♦
14.5k3925
accept rate: 35%

Hello,

Thanks for the reply. We actually do not get that option. The host server is Windows 2012R2. And as is expected PowerShell V4 is installed.

Gary.

alt text

alt text

link

answered 01 Sep '15, 19:56

lynodch's gravatar image

lynodch
1111
accept rate: 0%

Sorry, to get the update that you need to have to get this feature please download and install build v5.8 which you can get from the following page.

http://www.poweradmin.com/servermonitor/preview.aspx

Thanks
Quinn

Please make sure to mark your questions accepted when you have your answer by clicking the gray check mark to the left of the answer.

link

answered 02 Sep '15, 12:07

Quinn's gravatar image

Quinn ♦♦
14.5k3925
accept rate: 35%

Thank you.

After installing the preview version, the script now works.

However, I did expect based on previous posts to see options for PowerShell V2 and V4? We've only got V2 options, as pictured. Is that correct? (just so I know for the future).

alt text

Regards Gary

link

answered 02 Sep '15, 19:19

lynodch's gravatar image

lynodch
1111
accept rate: 0%

Sorry I miss lead you. The new setting is in version 6 of the product and that version is in Beta. Again I apologize for sending you to the preview version and now to the Beta version.

http://www.poweradmin.com/servermonitor/beta.aspx

Thanks
Quinn

Please make sure to mark your questions accepted when you have your answer by clicking the gray check mark to the left of the answer.

link

answered 03 Sep '15, 15:07

Quinn's gravatar image

Quinn ♦♦
14.5k3925
accept rate: 35%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×10
×1

Asked: 30 Aug '15, 20:12

Seen: (+: (DEFAULT: ), 1) times

Last updated: 03 Sep '15, 15:07