Powershell V2 – CannotIndex error when working with arrays

Ever had the cannotindex runtime exception when working with powershell arrays? I present the following situation: Create three .txt files and verify their creation with get-childitem *.txt. PS C:\Users\administrator.HOMELAB> echo 1 > 1.txt PS C:\Users\administrator.HOMELAB> echo 2 > 2.txt PS C:\Users\administrator.HOMELAB> echo 3 > 3.txt PS C:\Users\administrator.HOMELAB> Get-ChildItem *.txt     Directory: C:\Users\administrator.HOMELAB Mode                LastWriteTime     Length […]

SQL Server 2012 Express and remote connections

During the installation of a BES10.1.1 proof of concept I noticed my fresh SQL Server 2012 Express instance was not accepting remote connections. After a short investigation I learned that a SQL Server Express installation does not listen for remote connections out of the box. How to enable remote connections? 1) Enable the TCP/IP protocol […]

Installing Windows Server Update Services on Windows Server 2012 with PowerShell

I will describe how to install a Windows Server Update Services (WSUS) on W2012 using powershell. Some notes: This will be an autonomous installation which will fetch updates directly from Microsoft Update; The database will be the default  Windows Internal Database called “SUSDB” located in C:\Windows\WID\Data. First install the Windows Update Services Role and the […]

Useful powershell commands

I’ve been using Powershell more often the last year and a half. Looking back almost all of my Powershell adventures start with the same few commands: get-command When I’m looking for a cmdlet to perform an action I use get-command to find suitable cmdlets.  For example get-command *move*  will list all cmdlets with move somewhere in […]