PowerShell Direct Broken Unfortunately my Sunday afternoon of planned study has been slightly derailed, as last night I just upgraded my primary work machine to Windows 10 Build 10586. Everything went fine with the upgrade and seemed to be working just perfectly. However, when I started to get to work with my Hyper-V lab machines today I ran into a significant bug with PowerShell on this build:
PowerShell Direct no longer connects to any of my VMs.
In this latest video on Channel 9 Jeffrey Snover (the grand wizard of PowerShell) is suggesting might be on the horizon in Windows Server 2016. In it he is saying they are looking at using Pester (or a form of it) to allow you to create Operational Validation tests for your servers and environment so that after any environmental changes are made the environment is validated automatically. This sound like a fantastic idea to me and such an obvious fit to Pester.
In most situations in PowerShell, I am really only interested if a variable has a value or not (e.g. not null). Checking for this is easy:
[sourcecode language=“powershell”] if ($myvariable -eq $null) { Write-Host -Message ‘$MyVariable is null’ } else { Write-Host -Message ‘$MyVariable has a non-null and non-blank value’ } [/sourcecode]
But what if I want to know if a variable is not declared at all? The method of doing that is not so obvious and being PowerShell there are many ways of doing it.
Recently I’ve been helping resolve a couple of issues with the behavior of the xFirewall resource in the xNetworking DSC Module. One of these was trying to implement both the Group and DisplayGroup parameters when creating a new Firewall Rule.
A Firewall Rule Group/Display Group.
The obvious assumption is that the Group and DisplayGroup parameters behave in a similar fashion to the Name and DisplayName parameters. Unfortunately, this is not the case and it took me quite a lot of digging to figure out how they actually work.
Introduction I’ve been spending a bit of time lately working on some issues and improvements on the xNetworking DSC Resource so haven’t been spending as much time working on the series of File Server Resource Manager (FSRM) DSC Modules as I’d like. That said, I have managed to complete another module. This one is used for configuring Classification Properties and Property Values, Classification Configuration and Classification Rules.
If you missed any of the previous FSRM DSC Modules: