Skip to content

Category: Microsoft

Create a PowerShell Object from contents of a file

No doubt you already use PowerShell for a wide range of tasks and consequently are already familiar working with PowerShell objects? This post explains how to turn the contents of a file into a PowerShell object. You can then use this object for whatever you need. Say you have a file in C:\data\ with the content: hostname=file-server-1 os=Windows 2012R2 location=Digbeth city=Birmingham installed=01-06-2015 active=yes Now you create a PowerShell function that will take the above content…

Leave a Comment

Windows Server 2019 Template Issues

I experienced this issue when working on a particular platform, it was a weird one so thought I would document it. The Issue I had a Windows Server 2019 template that I had created and tested deploying within vCenter, no issues at all. I then proceeded to create a blueprint in vRA (vRealize Automation) to allow Windows Server 2019 VMs to be built. Tested a build and failed (timed out and deleted). Windows was just…

Leave a Comment

Generate SSL Certificate on Windows

SSL certificates are needed for a variety of reasons and depending on your environment it can be very easy or very hard to get the certificate(s) you want created. This is a nice easy method of generating a certificate on Windows. Put the below text into a file and save it as “{FQDN}.inf”. All the value between { and } should be changed to your required values, other than the 2.5.29.17 = “{text}” line, this…

Leave a Comment

Sysprep Fails on Windows 2008 R2 with PowerShell 5.0 Installed

I experienced this issue when working on a particular platform, it was a weird one so thought I would document it. The Issue I tried to deploy a VMware VM from a Windows 2008 R2 Template which had PowerShell 5.1 installed – Windows Management Framework (WMF) 5.0, however OS customisation would not complete. I tried to manually run sysprep within Windows too but that failed. Looking at the sysprep logs showed the error… “Sysprep_Generalize_MiStreamProv: ****…

Leave a Comment