创建一个服务

New-Service -Name testService -Description "This is a test service" -BinaryPathName "C:\Windows\system32\svchost.exe -k netsvcs -p" -DisplayName ExecutNote -StartupType Automatic

  

执行删除/启动:  sc delete testService / sc start testService

猜你喜欢

转载自www.cnblogs.com/feiyucha/p/10633424.html