How to start a windows service using PowerShell?


To start a specific windows service, you need to use Start-Service command.

Example

Start-Service -Name Spooler

Above command, will start the service name spooler. To check if service is started, use Get-Service –Name Spooler command.

Output

Status Name DisplayName
------ ---- -----------
Running spooler Print Spooler

This command will not show the command progress. To check the command progress, use –Verbose parameter.

PS C:\> Start-Service -Name Spooler -Verbose
VERBOSE: Performing the operation "Start-Service" on target "Print Spooler (Spooler)".

You can also start the service with,

Get-Service -Name Spooler | Start-Service -Verbose
PS C:\> Get-Service -Name Spooler | Start-Service -Verbose
VERBOSE: Performing the operation "Start-Service" on target "Print Spooler (Spooler)".

Updated on: 22-Jan-2020

2K+ Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements