Building Hyper-V Labs With Packer And Vagrant - Part 1

This two part series will cover the process to automate many of the repetitive tasks we need to perform when building simple lab environments. Labs are one of the best ways to learn and explore but I’ve been finding myself growing more reluctant to spin them up as it always took…

Determining Which Process Is Making SMB Requests On Windows

How would you go about finding what process was making SMB requests on a Windows PC? If you’re like me you probably answered either or PowerShell’s . These are the commands I reach for whenever I needed to link a process to a network connection, but the case isn’t so simple for…

Getting MX, SPF, DMARC, DKIM, and SMTP Banners With PowerShell

When diagnosing email issues I tend to start with some basics: MX records, SPF, DMARC and DKIM data. There are a multitude of ways to get these, but I tend to like working in PowerShell, so I wanted to write a function to quickly pull this data. Further, I also like to ensure I…

How To Query APNIC WHOIS With Powershell

I’m finding myself frequently needing to query APNIC for IP WHOIS data, and while I tend to always have a PowerShell prompt (or 17) open, I rarely have the APNIC site handy, so I thew together a little function that sits in my which hits the APNIC search endpoint and returns the…

PowerShell Sleep Duration Accuracy and Windows Timers

I’ve previously written about different methods of pausing PowerShell script execution but it’s spread over several unrelated posts and it was never the core topic being covered so I wanted to put it all together into a single place. You may want to ‘sleep’ or ‘suspend’ a script…

Analyzing Thread CPU Utilization with ProcessExplorer, PowerShell, and WMI

In a previous post we examined ways to get per core CPU performance data using PowerShell and WMI, and there was a question that we mostly glossed over - how do we know when a thread is CPU bound? A simple but unreliable method was to look at the CPU usage of a process, and if…

Scripting SQL Server Management Studio (SSMS) Installation

Very short post today. I found myself deploying SQL Server Management Studio (SSMS) to a number of systems and quickly got over clickety-clacking my way through it, so here is a PowerShell one liner to do just that. It always installs the latest version, and even cleans up after…

Analyzing CPU Usage With Powershell, WMI, and Excel

I recently needed to cobble together quick and dirty CPU monitoring to tackle an issue, and not being a huge fan of perfmon I decided to use PowerShell to pull the data and write it to a CSV file that I could analyze with PowerShell and Excel. This has the advantage of being…