When we shipped DC4, we started looking at Windows PowerShell and how we could build some integration points with our products. The first pass was a set of PowerShell script files that we introduced in the PowerShell Labs section of DevCentral. No soon after we posted them, the requests started pouring in on when we would provide some native PowerShell CmdLets in addition to the function scripts.
Well, I spent a little bit of time working some out and whipped out a good first rough draft. I've been holding on to these for a while now but figured they would do better out in the wild then trapped in a folder on my laptop.
So, last night I posted an installer for the first release of the iControl CmdLets for PowerShell. Here's a step by step on getting up and running with the new bits.
Download and install PowerShell from Microsoft
Go to the PowerShell Labs page on DevCentral and select the "Download Now" link. This will download the Cmdlet installer.
Run the iControlSnapInSetup.msi installer. This will install the SnapIn into the c:\program files\F5 Networks\iControlSnapIn directory.
Start PowerShell from the Windows Start menu.
Cd to c:\program files\F5 Networks\iControlSnapIn directory
Dot Source the setup script (only once after the install)
PS > . .\setupSnapIn.ps1)
Load the SnapIn into the Runtime
PS > Add-PSSnapIn iControlSnapIn
Initialize the iControl connection with the Initialize-F5.iControl CmdLet
PS > Initialize-F5.iControl -Hostname bigip_address -Credentials (Get-Credential)
Run the Get-F5.iControlCommands CmdLet to list out all the available Cmdlets.
PS > Get-F5.iControlCommands
Try out some of the CmdLets
PS > Get-F5.LTMPool
Notes From the Legacy Download:
Comment made 08-Jun-2016 by Patrik Jonsson
Needed to add .Net 2.0 in add/remove windows features. Then it worked in Windows 10. The installation script should be changed to throw and error if the installutil file does not exist instead of quitting silently.
Ken B Comment made 22-Jun-2016 by Ken B
The problem I had getting this working was that I had to right-click the downloaded .zip file, properties, and click the "unblock" button on the General tab. Then I had to copy the files from the .zip to a folder under c:\Program Files\f5\icontrol. Then I ran PS As Administrator, then ran .\setupSnapIn.ps1, then I was *finally* able to run the "Add-PSSnapIn iControlSnapIn" command to get things going.
Comment made 17-Jan-2017 by Joel Newton
You can update the InstallPSSnapin.ps1 script to reference the .NET v4 install utility. Just replace the reference in setupSnapin.ps1 from