如何在PowerShell中启动依赖服务?

要在PowerShell中启动依赖服务,与使用–Force参数停止依赖服务不同,因为没有可用的–Force参数。

您需要首先获取相关服务,然后再启动它们。

Get-Service -Name Winmgmt -DependentServices | Start-Service -Verbose