Home Dashboard Directory Help
Search

Restart-Service - wrong service name in code examples by Shay Levi


Status: 

Active


1
0
Sign in
to vote
Type: Bug
ID: 773500
Opened: 12/5/2012 12:44:05 AM
Access Restriction: Public
0
Workaround(s)
view
0
User(s) can reproduce this bug

Description

If you try the code in the first example of the Restart-Service cmdlet you'll get a "Cannot find any service with service name 'wmi'.", that's because there's no 'wmi' service, the name of the service is 'winmgmt'.


-------------------------- EXAMPLE 1 --------------------------

PS C:\> restart-service wmi


This command restarts the Windows Management Instrumentation (WMI) service on the local computer.
-----------------------------------------------------------------------
Details
Sign in to post a comment.
Sign in to post a workaround.