当我尝试启动一个Windows Service时遇到了一个报错
Error 1053: The service did not respond to the start or control request in a timely fashion.
我在网上查了很多资料有的说需要设置注册表,有的说可能是dll文件损坏什么,我都尝试修复了,但还是不行。
因为这个windows service之前时可以启动的,后来回想了一下成功和失败的这两次只有配置文件有区别,最后发现应该是配置文件中的配置项里有些值没有配置导致程序在windows service中启动时出现了异常导致的这个错误。
在这之后将程序的配置文件修改了一下果然问题解决了。
参考链接: