O'Reilly logo

Windows PowerShell™ 3.0 Step by Step by Ed Wilson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Obtaining service information: step-by-step exercises

In this exercise, you will explore the use of the Get-Service cmdlet as you retrieve service information from your computer. You will sort and filter the output from the Get-Service cmdlet. In the second exercise, you will use WMI to retrieve similar information. You should compare the two techniques for ease of use and completeness of data.

Obtaining Windows Service information by using the Get-Service cmdlet

  1. Start the Windows PowerShell console.

  2. From the Windows PowerShell prompt, use the Get-Service cmdlet to obtain a listing of all the services and their associated status. This is shown here:

    Get-Service

    A partial listing of the output from this command is shown here:

    Status Name DisplayName ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required