PowerShell Team

Automating the world one-liner at a time…

Latest posts

Mar 10, 2014
Post comments count 0
Post likes count 0

PowerShell Summit North America

PowerShell Team

We are delighted to draw attention to this year's PowerShell Summit - an excellent community run PowerShell event. As described by PowerShell.Org: Come meet the Windows PowerShell team, PowerShell MVPs, independent experts, and your peers and colleagues in the PowerShell universe! The PowerShell Summit is a one-of-a-kind annual event, and this year it’s April 27-29 right in Microsoft’s home town of Bellevue, Washington. You’ll enjoy more than 63 in-depth technical sessions about PowerShell, how to manage using PowerShell, how to develop in PowerShell, how to troubleshoot in PowerShell – pr...

Feb 28, 2014
Post comments count 0
Post likes count 0

Want to Automatically Configure Your Machines Using DSC at Initial Boot-up?

PowerShell Team

Often times, IT Pros want to automate software installation and configuration upon a machine’s initial boot-up. This blog will walk you through how to use Windows PowerShell Desired State Configuration (DSC) to do this. We will show you how to prepare and inject DSC configurations into your bootable media (such as VHDs), so that they are executed during the initial boot-up process. We will discuss three approaches to this process, and give a VHD example for each one. Prerequisites: Option 1 – Inject a DSC configuration (.ps1) into a VHD Our first approach will be to inject a .ps1 with a DSC config...

Feb 25, 2014
Post comments count 0
Post likes count 0

Reusing Existing Configuration Scripts in PowerShell Desired State Configuration

PowerShell Team

You are an expert in PowerShell DSC (or maybe not an expert, just someone playing around with configurations in DSC) and have already written fairly large and complex configurations for configuring your environment/data center. Everything is working well and you are a great fan of DSC. There’s only one problem: your work is complicated. Before long, you have a configuration that is hundreds or thousands of lines long – people from many different teams are editing it. Finding and fixing problems becomes nearly impossible… your configuration is just too unwieldy. Then comes a day when there arises a need to add...

Feb 13, 2014
Post comments count 0
Post likes count 0

Configuring a SQL High Availability Group with DSC

PowerShell Team

Let's use DSC to configure something complicated!  In past blogs, we’ve shown you how to use Windows PowerShell Desired State Configuration (DSC) to configure relatively simple systems.  However, the technologies you deal with on a day to day basis can sometimes become complicated.  Don’t worry, DSC can still help simplify configuration.  Let’s use SQL AlwaysOn Availability Group (AG) as a example. SQL AG is a new SQL feature that enables replication on top of Windows Server Failover Clustering. While the feature is cool, configuring the environment is quite complex. It involves many steps across multiple machi...

Feb 11, 2014
Post comments count 0
Post likes count 0

DSC Diagnostics Module– Analyze DSC Logs instantly now!

PowerShell Team

Have you ever witnessed a DSC Configuration run where you had no idea about what it might have done behind the scenes? Well, then your worries end here! During any DSC Operation, the DSC engine writes into windows event logs, which are like bread crumbs that the engine leaves along the way during any execution. If you read the blog here about DSC troubleshooting, you could learn how to use the Get-WinEvent cmdlet to debug a DSC failure using event logs. However, something that really simplifies life is the new module that has been published in Wave 2 of the DSC Resource Kit , called xDscDiagnostics. Introducti...

Feb 7, 2014
Post comments count 0
Post likes count 0

Need more DSC Resources? Announcing DSC Resource Kit Wave 2

PowerShell Team

Good news everyone! Starting today, you can use Windows PowerShell Desired State Configuration (DSC) to configure Active Directory and SQL Server (including High Availability Groups). We are pleased to release the next wave of the DSC Resource Kit – one that enables you to start using DSC to solve your real world problems and scenarios. When we shipped DSC in Windows Server 2012 R2, we shipped a platform with great infrastructure for configuration.  The next step for any platform like DSC is the creation of resources to make it immediately usable in significant real world scenarios.  With the resources we ship...

Feb 4, 2014
Post comments count 0
Post likes count 0

How to enable Updatable Help for your PowerShell Module

PowerShell Team

PowerShell 3.0 lets the user update Help content on a per module basis. In this article, I will explain how you can enable this for your own PowerShell module. Prerequisites: Have a new (script/binary) module, help content for the cmdlets of the module, and a server where the help content is located. For this particular exercise I will be using a script module. Here is how my module is organized: C:\Users\frangom\Documents\WindowsPowerShell\modules\TestModule\TestModule.psm1 C:\Users\frangom\Documents\WindowsPowerShell\modules\TestModule\TestModule.psd1 TestModule.psm1 is my script module. There, I defined...

Jan 31, 2014
Post comments count 0
Post likes count 0

Want to secure credentials in Windows PowerShell Desired State Configuration?

PowerShell Team

As you start using Windows PowerShell Desired State Configuration (DSC), you might need to specify credentials for resources. In a previous post we showed you how to define a resource that has a credential property.  In this post, I’ll discuss how to properly encrypt credentials when used in a DSC configuration. Prerequisites First, let us discuss the requirements to encrypt a DSC configuration. o   It is important that you keep the private key secure.  Since the public key is all that is needed to encrypt, I recommend you only export the public key to the machine you are writing your configu...

Jan 9, 2014
Post comments count 0
Post likes count 0

Separating “What” from “Where” in PowerShell DSC

PowerShell Team

As you already know we introduced PowerShell Desired State Configuration to the world at our TechEd NA 2013 Session. The session also introduced the notion of structural configuration (what) and environmental configuration (where) (at the 25:50 min mark). Structural configuration defines what is needed and does not change based on the environment. For instance, a configuration can require IIS to be installed – whether we have one node, or many nodes, whether it is a development environment or a production environment. It does not matter - we need IIS installed. Environmental configuration defines the environmen...