Creating Hyper-V VM’s with Desired State Configuration

I'm looking to automate the build of my test environment that runs as Hyper-V virtual machines on my Windows 8.1 Laptop computer. To get started, I thought I would take a look at the xHyper-V DSC resource to create the actual VM's. There's also no reason this shouldn't work on a Windows Server that's running the Hyper-V role. The Hyper-V role has already been added to my Windows 8.1 computer. I also have a previously created virtual hard drive (vhdx) file that has been loaded with the Windows Read more [...]
Posted in Desired State Configuration, Hyper-V, PowerShell, Windows 8.1 | Tagged , , , | Leave a comment

Awarded the SAPIEN MVP Award by SAPIEN Technologies, Inc

I received notification earlier this week that I've been awarded the SAPIEN MVP award for 2015 by SAPIEN Technologies, Inc. As many of you know, I co-authored SAPIEN's Windows PowerShell TFM 4th Edition which is one of the few books on the market that covers PowerShell version 4. I was one of the beta testers for PowerShell Studio 2014. Since I had early access to the product, it only made sense to write a chapter about that product in the new Windows PowerShell TFM book. What Read more [...]
Posted in PowerShell, SAPIEN Technologies | Tagged , | 1 Comment

How to check the PowerShell version & install a new version

In my last blog article I demonstrated "Where to Find & How to Launch PowerShell". Today I'll continue on to the next step which is determining what version of PowerShell you have installed. PowerShell version information is contained in the $PSVersionTable automatic variable. You can type out $PSVersionTable in the console window that you opened in the last blog article or you can type $psv and press tab to take advantage of what's called tabbed expansion:In Read more [...]
Posted in PowerShell | Tagged | Leave a comment

Where to Find & How to Launch PowerShell

Happy New Year! What better way to start the new year out than by setting some goals and what better goal to set than to learn PowerShell this year. Let's start out at ground zero by learning how to launch PowerShell. On Windows 8 or 8.1, simply start typing the word PowerShell on the Metro interface screen: Maybe you're still running Windows 7? If so, the shortcuts for PowerShell are located in the start menu under All Programs > Accessories > Windows PowerShell: Notice in Read more [...]
Posted in PowerShell | Tagged | 1 Comment

Mount an ISO on a Physical Server running Server Core

So you need to mount an ISO on a physical server that is running Windows Server 2012 R2 Server Core? If so, how would you accomplish that task without a graphical user interface? With PowerShell of course, specifically the Mount-DiskImage PowerShell cmdlet:By default nothing is returned when using the Mount-DiskImage cmdlet and the ISO is mounted using the next available drive letter. The -PassThru parameter was specified in the previous example but notice Read more [...]
Posted in PowerShell, Windows Server 2012 R2 | Tagged , | Leave a comment

PowerShell One-Liner: Create a new Hyper-V VM

My test environment resides on a workstation that runs Windows 8.1 Enterprise Edition with the Hyper-V role enabled. I need to create a new VM that will be used as a second domain controller in my test environment. I'll use a PowerShell one-liner to create this new VM which will use a differencing disk based on a Windows Server 2012 R2 vhdx that has been fully patched and syspreped:µ Read more [...]
Posted in Hyper-V, PowerShell | Tagged , | Leave a comment

Presenting for the Singapore PowerShell User Group PowerBreakfast 007: What’s New in PowerShell Version 5

I'll be presenting a session on "What's New in PowerShell Version 5" for the Singapore PowerShell User Group's PowerBreakfast #007 this Saturday, December 13th beginning at 8:30am (Singapore time). Sign up on Eventbrite if you're interested in attending this event. Here's what you can expect from this presentation: With PowerShell version 4 being announced at TechEd last year (2013) and several preview versions of PowerShell version 5 already being released this year, it shows how committed Read more [...]
Posted in PowerShell | Tagged | Leave a comment

Use a certificate with PowerShell DSC to add a server to Active Directory without hard coding a password

A new Windows Server 2012 R2 machine has been brought online and needs to be joined to your Active Directory domain. All machines used in this demonstration are running either Windows Server 2012 R2 or Windows 8.1 with PowerShell version 4. You've decided to use DSC (Desired State Configuration) to join this new server to the domain because it's a prototype for many more servers to come. You plan to automate their deployment along with the majority of their configuration with DSC. While this Read more [...]
Posted in Desired State Configuration, PowerShell | Tagged , , | 2 Comments

Using PowerShell to add the necessary vWorkspace Firewall Exceptions on a Hyper-V Host Virtualization Server

Recently while adding a Windows Server 2012 R2 Hyper-V server as a host virtualization server in a vWorkspace 8.0.1 environment, I received the following error message: "Connect to DC service timed out. Overlapped I/O operation is in progress. (997) Retry will occur automatically if necessary." That error message lead me to a Dell support article which stated that I needed to either disable the firewall <which is not going to happen on my watch> or open port 5203. While the article Read more [...]
Posted in PowerShell, vWorkspace | Tagged , | Leave a comment

Use PowerShell to Install Active Directory Certificate Services

In this blog article, I'll use PowerShell to install Active Directory Certificate Services in my test environment. The domain controller that's being used is running Windows Server 2012 R2 Server Core Installation (no-GUI). The workstation that I'm using is running Windows 8.1 and it is a member of the same Active Directory domain. Many times when I'm prototyping something on a single remote server, I'll use one to one remoting so that it's an interactive session. The Enter-PSSession cmdlet is Read more [...]
Posted in Active Directory, PowerShell | Tagged , | Leave a comment

My New Book: Windows PowerShell TFM 4th Edition is now Available!

If you work with technology then I'm sure you're already aware that PowerShell is one of those technologies that is quickly becoming a must have skill. Whether you're a beginner or someone who is looking to become more proficient with PowerShell, there's a new book on the market that is an all in one learning guide, lab guide, and PowerShell reference. I'm happy to say that I'm proud to be part of the Superhero team at SAPIEN Technologies who is bringing you the Windows PowerShell TFM 4th Edition Read more [...]
Posted in PowerShell | Tagged | 4 Comments

PowerShell: When Best Practices and Accurate Results Collide

I'm a big believer in trying to write my PowerShell code to what the industry considers to be the best practices as most are common sense anyway, although as one person once told me: "Common sense isn't all that common anymore". I would hope that even the most diehard best practices person would realize that if you run into a scenario where following best practices causes the results to be skewed, that at least in that scenario it's worth taking a step back so you can see the bigger picture. I Read more [...]
Posted in Active Directory, PowerShell, SQL Server | Tagged , , | Leave a comment