Mark Minasi's Tech Forum
Register Calendar Latest Topics Chat
 
 
 


Reply
  Author   Comment  
DM-AVAL

New Friend (or an Old Friend who Built a New Account)
Registered:
Posts: 69
Reply with quote  #1 
Exchange 2010 (and 2013/2016) is now compatible with PowerShell 4.0. Sort of...

More details here (my post is from July 20 - David M):

https://social.technet.microsoft.com/Forums/exchange/en-US/a7bc38e5-abce-48bf-ab8f-ac3bf80462ef/startdagservermaintenance-fails-during-checkdatabaseredundancy?forum=exchangesvrdeploylegacy#a87b78f2-139c-442c-8b7e-6b5ac96b0cc3

But not much feedback.

Maybe because Exchange 2010 is in extended support and fewer and fewer people are using it?

Not to mention everyone that's now in the Cloud with O365...

Anyway, has anyone here encountered this type of problem?

Perhaps more importantly, does anyone know how to make Exchange run the script with PS 2.0?

Or does something in the script need to be updated?

Could there be a newer version of the script (that would still work with Exchange 2010)?

I'm at Exchange 2010 SP3 RU14 (Windows 2008 Server R2 SP1)

Thanks!

(Yes, still working with Exchange!)
0
jsclmedave

Administrator
Registered:
Posts: 445
Reply with quote  #2 
David, what is it you're trying to do..?



__________________
Tim Bolton @jsclmedave
Email: [string](0..20|%{[char][int](32+('527377347976847978324785847679797514357977').substring(($_*2),2))}) -replace ' '  

New to the forum? Please Read this
0
DM-AVAL

New Friend (or an Old Friend who Built a New Account)
Registered:
Posts: 69
Reply with quote  #3 
Execute the DAG maintenance scripts, respectively:

- StartDagServerMaintenance.ps1
- StopDagServerMaintenance.ps1

They have worked, literally, for years (two years).

After we upgraded PowerShell to PowerShell 4.0 (requirement for NetApp software), the command startdagservermaintenance.ps1 fails with the following error message: 

Exception setting "lastgreenreportedutc": "cannot convert null to type "system.datetime"."
at checkdatabaseredundancy.ps1:563 char:2

+ $dbredundancy.lastgreenreportedutc = $null

 + Categoryinfo:   NotSpecified:<:> [], SetValueInvocationException
 + FullyQualifiedErrorId: ExceptionWhenSetting

The original poster in the TechNet discussion was having the same problem. I followed up with a post (currently the last post) confirming that this is a problem.

I'm dissecting the script right now, seeing if I can't find something, or at least extract the appropriate PS cmdlets to be run manually.

0
jsclmedave

Administrator
Registered:
Posts: 445
Reply with quote  #4 
I found your post on TechNet as well...

refer to supportabily matrix note - not supported https://technet.microsoft.com/en-us/library/


__________________
Tim Bolton @jsclmedave
Email: [string](0..20|%{[char][int](32+('527377347976847978324785847679797514357977').substring(($_*2),2))}) -replace ' '  

New to the forum? Please Read this
0
DM-AVAL

New Friend (or an Old Friend who Built a New Account)
Registered:
Posts: 69
Reply with quote  #5 
Are you referring to this:

"Windows Management Framework 3.0 and Windows Management Framework 4.0 can be used to perform operating system-related management tasks on a computer that's running Exchange 2010 SP3 RU5 or later. However, Exchange 2010 cmdlets and Exchange 2010 scripts require Windows PowerShell 2.0. Using Exchange 2010 cmdlets and scripts with Windows Management Framework 3.0 or Windows Management Framework 4.0 isn't supported."

?

Doesn't PS 2.0 continue to exist on machines with a later version installed?

If I open the EMS (which apparently still uses PS 2.0), I would think the script would run in that context. No?

This is what the target property in the EMS shortcut is pointing to:

C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -version 2.0 -noexit -command ". 'E:\Program Files\Microsoft\Exchange Server\V14\bin\RemoteExchange.ps1'; Connect-ExchangeServer -auto"

Of course, in the end, the script will not run (correctly).
0
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Easily create a Forum Website with Website Toolbox.