When troubleshooting a system, you sometimes need to know what DNS lookups are being done. This will give you a good insight into traffic from the systems to the local network or internet. You can do this with DNS auditing on your Windows server or in your local Pihole server, but that's not always available 😉 This blog post will show you an easy way to create a report without extra tools.
Month: August 2022
Deploy a Hyper-V VM and register it for Autopilot automatically using PowerShell
I need a VM connected to the customer's tenant for Endpoint Manager testing. This involves deploying a Windows 10 or 11 VM, changing hardware settings (Secure Boot/TPM/Checkpoint settings), and registering it for Autopilot. This blog post will show you how to automate the process as much as possible.
Report on Active Directory Container permissions using PowerShell
In a previous blog post (Link), I showed a way to create a report on OU (Organizational Unit) permissions. One of the replies I got about that was: How about the Container permissions? Those are important too 🙂 And that's correct, they are! In this blog post, I will show you how to create a report on those (The script is based on the OU report)
Compact Hyper-V VHDX files using PowerShell
I used VMware Workstation for a while which has an option to automatically compact the virtual hard disk after shutting down the VM, an excellent way of freeing up space on my laptop hard drive. But I switched to using only Hyper-V now. Compacting virtual hard disks is not something you can enable in Hyper-V to run automatically. In this blog post, I will show you how to do this using a script that you can use to do that easily 🙂
Debugging PowerShell scripts in Visual Studio Code
When testing your new PowerShell script, it throws an expected error or isn't that reliable, and you're not sure why 🙁 The Visual Studio code debugging options could help you pinpoint the issue. In this blog post, I will show you how to do that.
Create a focus time countdown clock using PowerShell
Sometimes you need to finish something, and notifications from your running programs keep taking away your focus... You can try using the script in this blog post to keep focused on your task. When the count-down timer is done, your programs will be available again. Hope this helps 🙂
Create a TCP/UDP port listener using PowerShell
One of our customers is securing his network, and firewall changes were made that needed to be tested. In this case, the new servers were not yet deployed in that specific network. But... We did want to test the connections before deploying the servers 🙂 In this blog post, I will show you how to create listening ports on a machine to test the connection from another network using netcat on Linux or portqry on Windows.
PowerShell and JSON
JSON is something that's being used a lot. It's easy to store and retrieve data. In this small blog post, I will show you how to do that 🙂
Jupyter notebooks in VSCode with PowerShell support
Saw a video about Jupyter in Visual Studio Code a while back, tried to get it up and running, and... It seems that things are changed now. It was there in VSCode preview versions and the PowerShell preview extension. All the How-To's I found showed me that way of getting it installed/configured. So I played around with Jupyter and the PowerShell kernel installation and got it working in VSCode. In this blog post, I will show you how to install and configure everything 🙂
Create a Tweet on Twitter using PowerShell
In an earlier post about Slack, I showed you how to create a message there, but I also use Twitter a lot (I even met my girlfriend because of that!). In this blog post, I will show you how to create a Tweet using PowerShell 🙂