Windows服务 – ServiceController似乎无法停止服务
发布时间:2020-12-14 01:44:50 所属栏目:Windows 来源:网络整理
导读:我试图在本地机器上停止 Windows服务(服务是Topshelf.Host,如果重要)与此代码: serviceController.Stop();serviceController.WaitForStatus(ServiceControllerStatus.Stopped,timeout); 超时设置为1小时,但服务从未实际停止.奇怪的是,从服务MMC管理单元中我
我试图在本地机器上停止
Windows服务(服务是Topshelf.Host,如果重要)与此代码:
serviceController.Stop(); serviceController.WaitForStatus(ServiceControllerStatus.Stopped,timeout); 超时设置为1小时,但服务从未实际停止.奇怪的是,从服务MMC管理单元中我首先看到它在“停止”状态,但一段时间后,它恢复为“已启动”.但是,当我尝试手动停止时,会发生错误: Windows could not stop the Topshelf.Host service on Local Computer. Error 1061: The service cannot accept control messages at this time. 我在这里遗漏了什么吗?
您的服务正忙于处理一些大的操作或正在转换以更改状态.因此不能接受任何输入…只是想到它采取比它可以咀嚼更多…
如果你确定你没有给它任何东西,只需去任务管理器,杀死这个服务的过程或重新启动你的机器. (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- windows-8 – 在创建新的WinRT视图时指定视图提供程序类型
- powershell – 如果/ ElseIf阻止不使用-or
- windows-8 – 摆脱Metro界面
- 常用Windows命令、常用 Cmd命令
- wpf – 使用WindowManager重新激活退出窗口
- 如何在PowerShell中运行Windows安装程序并获取成功/失败的值
- windows-server-2012 – 什么是Server 2012 Essentials以及
- 适用于Windows Communication Foundation的Linux / Mac OS
- .net – 何时引用了Assemblies加载?
- windows-server-2003 – 完全格式化服务器以便在易趣上销售