PowerShell for Windows Admins:

Powershell


January 11, 2016  10:34 AM

Testing against an arrays contents

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
Powershell

You may need to test if a value is a member of an array. PowerShell provides 2 operators for testing array membership  - -   -in and –contains. Simple usage is like this PS> $colours = 'red', 'orange', 'yellow', 'green', 'blue', 'indigo', 'violet' PS> 'blue' -in...

January 8, 2016  1:49 PM

WMI discovery

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
CIM, Powershell, WMI

I’ve been working with System Center Configuration Manager this week. SCCM uses a lot of WMI. However, WMI discovery is still a bit of an art. I needed to find the SMS_SCI_Component class. If you know the namespace you can easily find the classes in that namespace but namespaces are...


January 4, 2016  9:29 AM

Starting to use PowerShell

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
Powershell

A common question goes along the lines of  “I've leant PowerShell (from class, book etc) but what do I do next?” The usual answer is to pick a problem in your organisation and solve it. I’ve provided an example in this UK TechNet blog post


January 2, 2016  10:34 AM

2015 December Scripting Games Puzzle

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
Powershell

The December 2015 puzzle was based on the 12 Days of Christmas song.  Starting with this here-string. $list = @" 1 Partridge in a pear tree 2 Turtle Doves 3 French Hens 4 Calling Birds 5 Golden Rings 6 Geese a laying 7 Swans a swimming 8 Maids a milking 9 Ladies dancing 10 Lords a...


January 2, 2016  6:43 AM

Happy New Year 2016

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
Powershell

A new year and a number of things to which we can look forward. The re-release of WMF 5.0. The WMF 5.0 download was pulled because a bug was over writing the module path. Look fot the download being available again soon. Windows Server 2016 – Containers and Nano server give lots of new...


December 23, 2015  6:45 AM

Objects, properties and values

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
Powershell

One thing that seems to keep causing confusion is using Select-Object to pick off one or more properties from a set of objects: PS> Get-CimInstance -ClassName Win32_Share | select Path Path ---- C:\WINDOWS C:\ C:\windows\system32\spool\drivers C:\Users The gap in the output is...


December 23, 2015  6:39 AM

Infrastructure as Code article

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DevOps, Powershell

My Infrastructiure as Code article – part of an introducing DevOps series – has gone live 0 Comments     RSS Feed     Email a friend


December 22, 2015  9:36 AM

BinaryMiLog cmdlets

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
CIM, Powershell, WMI

It’s not often I come across soemthing brand new in PowerShell but yesterday when I was investigating New-CimInstance I discovered 2 cmdlets in the CimCmdlets module I hadn’t noticed before. These are: Export-BinaryMiLog Import-BinaryMiLog The cmdlets are used to export, or import, CIM...


December 21, 2015  3:36 PM

New-CimInstance cmdlet and the–Key parameter

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
CIM, Powershell, WMI

I was asked a question about the –Key parameter on New-CimInstance today. I wasn’t sure of the answer so I’ve done some experimentation. I tend to avoid New-CimInstance if I can preferring to use the Create method on the CIM class – however not all CIM classes have a create method so...


December 21, 2015  5:41 AM

JEA Helper Tool 2.0

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
Powershell, Windows Server 2016

JEA – Just Enough Admin – is a security feature in WMF 5.0 and Windows Server 2016 (TP4) – providing RBAC for your Windows servers. You can allow people to perform the tasks needed by their role without giving them full access. An introductory document is available -


Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: