prunsrv.exe 服务未启动 [英] prunsrv.exe Service not starting up
问题描述
我正在尝试使用 prunsrv.exe 为应用程序安装和启动服务
I am trying to install and start a service with prunsrv.exe for an application
我可以正常安装该服务,但该服务无法启动并给我一个错误
I am able to install the service alright but the service wont start up and gives me an error
还有下面是使用prunsrv.exe安装服务的配置
Also following is the configuration that is used to install the service using prunsrv.exe
set SERVICE_NAME=TestService
REM Service log configuration
set PR_LOGPREFIX=%SERVICE_NAME%
set PR_LOGPATH=D:\setups\Commons_Daemon\commons-daemon-1.0.14-bin-windows\logs
set PR_STDOUTPUT=auto
set PR_STDERROR=auto
set PR_LOGLEVEL=INFO
REM Path to java installation
set PR_JVM=C:\Program Files\Java\jre1.6.0_04\bin\client\jvm.dll
set PR_CLASSPATH=D:\setups\Commons_Daemon\commons-daemon-1.0.14-bin-windows\temp.jar;
REM Startup configuration
set PR_STARTUP=auto
set PR_STARTMODE=java
set PR_STARTCLASS=Trys.AppLauncher
set PR_STARTMETHOD=start
REM Shutdown configuration
set PR_STOPMODE=java
set PR_STOPCLASS=Trys.AppLauncher
set PR_STOPMETHOD=stop
REM JVM configuration
set PR_JVMMS=64
set PR_JVMMX=128
set PR_JVMSS=4000
REM Install service
prunsrv.exe //IS//%SERVICE_NAME%
以上配置打包成批处理文件执行安装服务
The above config is packaged to a batch file is executed to install the service
也没有生成日志文件,因此我什至无法调试.
请告诉我哪里出错了
推荐答案
这个错误的原因是我没有将 prunsrv.exe
重命名为 TestService.exe
.同样,Prunmgr.exe 必须是 TestServicew.exe.
The reason for this error was that i did not rename prunsrv.exe
to TestService.exe
. Similarly Prunmgr.exe has to be TestServicew.exe.
重命名这些文件非常重要.
Very important that these files are renamed.
这篇关于prunsrv.exe 服务未启动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!