Get the IP Address of a VM Attached to an External Switch

My LabBuilder project is coming along nicely and it is building a large lab environment in Hyper-V within a few minutes. However, a problem I ran into was that sometimes the host couldn’t connect (using New-PSSession or equivalent) to a Guest VM to copy files or invoke commands. This was because I was usually using the computer name to connect to the Guest VM - which won’t always work. Instead using the IP address of the VM’s Virtual NIC that is attached to the External Switch.
Read full post gblog_arrow_right

Advanced Certificate Services Configuration with DSC

Recently I’ve been rebuilding my Hyper-V lab environment from scratch (as part of my MCSA/MCSE studying) and decided I would completely script the process using PowerShell only. My goal was to not require a single interactive session with any of the servers to setup the entire environment. This was a multi-site AD environment with several other member servers performing other duties including NPS & NAP, ADCS, WDS, WSUS, ADFS, ADRMS, IIS, DirectAccess, SQL etc.
Read full post gblog_arrow_right

Convert a Domain Name to a Distinguished Name in PowerShell

Here is a small PowerShell snippet to easily convert a Domain Name (e.g. corp.bmdlab.com) to a distinguished name (DC=corp,DC=bmdlab,DC=com): [sourcecode language=“powershell”] [String]$Domain = ‘corp.bmdlab.com’ # Create an empty string that the DN will be stored in [String]$DN = '' # Assemble the DN by splitting the DC and then looping to concatenate the new $Domain.Split(’.’) | % { $DN = “DC=$($_),$DN” } # An extra . will be left on the end of DN, so strip it off $DN = $DN.
Read full post gblog_arrow_right

The Demise of SMB1 in the Windows Stack

If you’re interested in SMB and the general progress of the protocol, I’d recommend this 30 minute video on Channel 9: The Demise of SMB1 in the Windows Stack. It motivated me to rid all my desktops and servers of SMB 1.0 the ancient and insecure protocol support. To disable SMB 1.0 on a Windows Server: [sourcecode language=“powershell”] Set-SmbServerConfiguration -EnableSMB1Protocol $false [/sourcecode] You can uninstall SMB 1.0 on a Windows Desktop:
Read full post gblog_arrow_right