Storage Informer
Storage Informer

PowerShell 2.0 Coming Soon – What’s New? – Part 1

by on Jul.10, 2009, under Storage

PowerShell 2.0 Coming Soon V Whats New? – Part 1

When Windows 7 and Windows Server 2008 R2 arrive later this year, PowerShell 2.0 will also make its debut as an integrated component for those operating systems and a Windows Update download for others like Windows XP, Windows Vista and Windows Server 2003.

A lot has changed in the newest release of this scripting language.  Over 70 new cmdlets are now available, along with the addition of remoting, background jobs, improved debugging, an integrated script editor and overall language enhancements.  Compellent will be integrating PowerShell 2.0 in our Storage Center Command Set for PowerShell for automated scripting.

Debugging PowerShell scripts in the 1.0 release provided some challenges.  Not that it was impossible, but to me, it seemed to still resemble debugging principles of VBScript more than those used in Visual Basic or C#.  Nonetheless, the ability to directly debug inside PowerShell code in version 2 is there and contains cmdlets for setting breakpoints (Set-PSBreakpoint) as well as stepping in and out of code for all you developer types.  How about the ability to use a Try/Catch/Finally for exception handling?  That’s in there too.

True enterprise integration and automation comes from being able to manage multiple components, servers, even environments from a single interface.  Remoting, something that seemed to be missing from the initial release of PowerShell will be available in v2.  Remoting will provide the capability to run PowerShell commands and scripts against a remote machine utilizing Windows Remote Management (WinRM) as the means to retrieve this information.  WinRM is the
Microsoft implementation of WS-MAN, a standards-based, firewall-friendly protocol that provides management information securely.

Provisioning storage via the Compellent Command Set for PowerShell using PowerShell v2 means that you can run a single script from a management workstation that will handle that provisioning process which can now include one or more servers which also run PowerShell v2 and the WinRM configured as a listener.

Background Jobs
Scripts run under PowerShell v1 issued commands in a synchronous fashion, meaning that once the command was issued a response would have to be received before the next command would execute.  In PowerShell v2, background jobs are introduced via cmdlets: Get-Job, Receive-Job, Remove-Job, Start-Job, Stop-Job, Wait-Job.  This now means that when a command is issued, PowerShell is immediately ready for the next command, even while the first command is still in process.

This fits in perfect with the storage provisioning automation we just talked about. What if we could provision storage to 5, 10, or 20 servers all at once?  That’s right … These jobs can run independently and on totally different machines.

Check out part two of this post next week where I’ll discuss more of PowerShell v2’s capabilities and features.


:, , , , , , , , ,

Leave a Reply

Powered by WP Hashcash

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...