要使用PowerShell启动多个服务,我们需要在服务之间使用逗号(,)。
例如,
Start-Service -Name Spooler,AdobeARMservice -Verbose
Get-Service -Name Spooler,AdobeARMservice | Start-Service -Verbose
要以显示名称启动服务,
Start-Service -Name "Print Spooler","Work Folder" -Verbose
Get-Service -Name "Print Spooler","Work Folder" | Start-Service -Verbose