Don Jones

Explore articles and content from this author

Don Jones

372 articles published

4 min read

More PowerShell v4 and DSC Details

Here’s what I know, much based on a TechEd talk this week:
We can expect PowerShell v4 to ship in the Windows Management Framework, as with previous versions. It will be preinstalled on Windows Server 2012 R2 and what they’re calling Windows 8.1; the default execution policy will be RemoteSigned, and on the server OS Remoting will be enabled by default. Microsoft’s past policy has been “current version and two back,” and if they follow that then we’ll get WMF 4.0 on Windows 7, Windows Server 2008 R2, and later. That would leave out Server 2008, if in fact they follow that same policy.
DSC itself starts with a PowerShell script that’s mainly declarative code: Make sure x is installed, make sure y isn’t installed, etc. PowerShell compiles that into a MOF, which can be transmitted to managed endpoints (computers). The built-in mechanisms for deployment aren’t as complex or flexible as GPO or SCCM targeting, but you could use either GPO or SCCM to deploy those MOFs. That’s the “push” model - you push MOFs out to managed nodes. A “pull” model requires you to configure managed nodes to have a URI and UDDI, and they check that URI for their MOFs.
DSC runs every 15 minutes or every 30 minutes by default, depending on whether you’re using push or pull, and you can configure that time. Right now there’s no feedback or reporting - it’s a bit like GPO, where you push out the setting and it enforces it, but that’s it.
When DSC runs, it takes your “desired state” MOFs and starts running “DSC resources.” These resources are special modules that implement a predefined set of functions - a Get, a Test, and a Set function, to be specific. I expect MS product groups to provide these - the Exchange team will likely someday provide resources that can check/set Exchange settings, for example. You can also write your own modules. DSC calls the “test” to see if your setting is or isn’t configured at that time; it calls the “set” to add/remove/whatever the setting. So the real work is done by these special modules - and those modules can do whatever they want. Write to the registry, run commands, call .NET classes, anything.
So there’s two scripts: The “desired state” script that gets compiled to a MOF (so you shouldn’t ever have to mess directly with MOFs yourself), and the “implementing module” that has the three special functions which actually do all the work.
In the “pull” model, those special modules can be dynamically downloaded by a managed node. “Hey, I grabbed this desired state MOF, and it seems to require 12 modules, so I’ll go to the same URI and look for those 12 modules.” You provide those modules as ZIPs, and PowerShell can grab the ZIP, expand it into the proper location, and then run the modules as needed.
Personal analysis (meaning this is my opinion, not something MS has said): I can see this DSC feature integrating super-well with some future version of SCCM. DSC writes out some local file with configuration details, and the SCCM client grabs it and feeds it up to the database. Those MOFs could potentially be pulled from a Distribution Point by the client, handed off to PowerShell, and run on a scheduled basis. I can also see DSC starting to supplant GPO in a lot of ways. After all, most GPO stuff is just reg hacks in a special section of the registry; there’s no reason DSC couldn’t do that - and it does it on a more frequent basis, making it more reliable. Right now, the targeting of a MOF isn’t as flexible as GPO targeting… but that could obviously evolve. Until more of the architectural details emerge, we won’t know for sure… and this is of course a v1 feature that will doubtless be expanded on and invested in as the team moves forward. We do know that the first release of DSC will not have a lot of those underlying “resource modules,” which means you won’t actually be able to configure much. This is a feature the team needs to put in place so that folks can start building those things… so this is going to take a cycle or two to start being really useful.
There’s obviously still a lot under wraps here, and this is all subject to change and tweaking as the team moves toward release. We’re told there will be some kind of public preview - but they haven’t announced a date on that. Personally, with the Build conference coming up, we can imagine that Microsoft will try and have a preview release ready for that show. There’s also no announcement of ship date. It’s still too early to tell, and I want to emphasize that the company hasn’t announced any dates. We can but try to make educated guesses at this stage.

2 min read

Scripting Games Event 5 Winners

We’re pleased to announce the winners for Event 5 of The Scripting Games 2013!
Remember that Event 6 is now open for community voting, and that Event 6 opens up near the end of this week. That’ll be your last chance to contribute, and shortly after TechEd we’ll announce the overall winners. Good luck!
Winners: You can log into The Scripting Games Web site and go to your Profile page to see your prize. You will be given a prize redemption code and either a URL where you can redeem it, or an e-mail address of the prize provider (they will need the redemption code). All prizes must be claimed by the end of July 2013. I will list winners by username; if you used your e-mail address as your username, then a portion of that will be truncated for your privacy. Anyone can log in and check their Profile page to see if they’ve won a prize.

2 min read

Microsoft announces PowerShell v4, DSC

Yesterday at TechEd North America, Jeffrey Snover and Kenneth Hansen began describing features to be delivered with PowerShell v4 in Windows Server 2012 R2 (the company has not yet announced availability dates for either).
In particular, a new feature called Desired State Configuration promises to become the foundation for some pretty serious expansion. Essentially, DSC lets administrators write a declarative “script” that describes what a computer should look like. PowerShell takes that, matches the declarative components with underlying modules, and ensures that the computer does, in fact, look like that. Nearly anything can be checked and controlled: roles, features, files, registry keys - anything, in fact, that a PowerShell module can do.
The architecture includes the notion of centrally stored declarative scripts, and the ability to dynamically deploy supporting modules on an as-needed basis to computers that are checking themselves. A System Center Virtual Machine Manager demonstration utilized the feature to dynamically spin up brand-new VM instances and have them immediately reconfigure to their desired state.
At first glance, it’s easy to see “more Microsoft stuff” in this feature. After all, the company has previous given us Dynamic Systems Management (DSM), various universal “configuration languages,” and even System Center Configuration Manager’s somewhat primitive configuration auditing feature. But keep in mind that DSC will be a core part of the OS. That means product teams and ISVs can rely on it being there, with no other dependencies to worry about. DSC is also built around DMTF standards - like the MOF format - making it natively suitable for cross-platform management. A demo from Opscode using their Chef product showed clever use of the new DSC feature.
Hansen also mentioned that PowerShell modules will be deployable through DSC as ZIP files, helping make them more self-contained (not entirely unlike PECL packages in the Unix world).
There has been no announcement as yet on how far back PowerShell v4 will be made available, nor whether or not DSC is a PowerShell feature or a Windows Server 2012 R2 feature. If it is indeed a PowerShell feature (which I suspect it is), then it’ll be available on any system with v4 installed. That will hopefully include at least Windows 7, Windows Server 2008 R2, and later.

2 min read

As The Scripting Games Wrap Up…

We’ve still got, oh, about 48 hours or so for Event 6 submissions, and then of course voting and judging. But I wanted to take a second and let you know what this year’s Games looked like:
We’ve logged over 1,100 entries. Almost 13,000 votes. More than 6,700 comments. That’s a lot - and it’ll all be archived once the final votes are tallied and prizes awarded. There will be ZIP files of entries for each track and event, and I encourage you to download them over the Summer - we won’t necessarily archive them permanently.
We’ve seen an enormous range of techniques and approaches, and generated hundreds of learning notes across more than a dozen active expert commentators. We’ve awarded - with some yet to be handed out - thousands of dollars worth of prizes.
This is also a good time to start collecting general feedback on the Games, so feel free to drop into our official post-mortem thread and offer your feedback. Read the introductory post in that thread before you post, please. I’m asking for a specific feedback format at this time, although you’re always welcome to open your own thread if you have something specific or off-format you want to offer. I ask only that you keep things constructive and professional.
Thanks to everyone who participated in the Games. We’re formulating our next event, so stay tuned.

1 min read

Free PowerShell Workshop Video from TechMentor and Me

At the last TechMentor (in Orlando), I did a Windows PowerShell pre-conference workshop. The conference was kind enough to let me record it - I basically just used Camtasia, so this isn’t a professional video by any stretch, but it gives you an idea of what a TechMentor conference is like. Obviously, my focus was on the folks in the room, but you can see all of the demos and hear me pretty clearly. You can view the video for free, although note that registration is required.

2 min read

"Super Secret" Snover Session at TechEd

So what’s with the “super secret” PowerShell session being given by Jeffrey Snover at TechEd 2013?
First, if you’ll be in New Orleans, plan to attend this. The deal is pretty simple: Microsoft has got a lot of information pertaining to v.Next under embargo, which means people can’t talk about it yet, or even tell you the title of the session. But trust me, if you’re interested in the world of DevOps (and if you use PowerShell, you are), you’ll want to be at this session. PowerShell MVPs were given a sneak peek at what Snover will be discussing, and it’ll frankly blow your mind. It will, over the long haul, put PowerShell in a completely new place - and you’ll want to get in on the ground floor.
Like most sessions at TechEd, it appears as if they’ll be recording this, so even if you can’t attend in person be sure to check back once the recording is live. That usually takes a day or two after the talk itself.
And spread the word a bit. There’s a bit of a worry that, because even the title of the session won’t be announced until TechEd formally commences, folks won’t have much time to realize the session exists and it’ll go empty. We don’t want that to happen - as with any new developments in PowerShell, it’s crucial to get folks thinking about it early, to get their feedback early, and to start planning for it early.

2 min read

Scripting Games Event 4 Winners

We’re pleased to announce the winners for Event 4 of The Scripting Games 2013!
Remember that Event 5 is now open for community voting, and that Event 6 opens up near the end of this week. That’ll be your last chance to contribute, and shortly after TechEd we’ll announce the overall winners. Good luck!
Winners: You can log into The Scripting Games Web site and go to your Profile page to see your prize. You will be given a prize redemption code and either a URL where you can redeem it, or an e-mail address of the prize provider (they will need the redemption code). All prizes must be claimed by the end of July 2013. I will list winners by username; if you used your e-mail address as your username, then a portion of that will be truncated for your privacy. Anyone can log in and check their Profile page to see if they’ve won a prize.