Unable to Configure Confluence to Run as a Service on Tomcat 5
The following message appears when installing the service:
C:\confluence\confluence-2.7-std\bin>echo %java_home% C:\Progra~1\Java\jdk1.6.0_04 C:\confluence\confluence-2.7-std\bin>service.bat install Confluence Installing the service 'Confluence' ... Using CATALINA_HOME: C:\confluence\confluence-2.7-std Using CATALINA_BASE: C:\confluence\confluence-2.7-std Using JAVA_HOME: C:\Progra~1\Java\jdk1.6.0_04 Using JVM: C:\Progra~1\Java\jdk1.6.0_04\jre\bin\server\jvm.dll The service 'Confluence' has been installed. C:\confluence\confluence-2.7-std\bin>tomcat5 //US//Confluence --Startup auto C:\confluence\confluence-2.7-std\bin>net start Confluence The Apache Tomcat Confluence service is starting. The Apache Tomcat Confluence service could not be started. A service specific error occurred: 0. More help is available by typing NET HELPMSG 3547.
The Confluence logs show the following error:
[2008-10-30 15:13:15] [947 prunsrv.c] [error] Failed creating java C:\jdk1.6.0_10\jre\bin\server\jvm.dll [2008-10-30 15:13:15] [1202 prunsrv.c] [error] ServiceStart returned 1
Tomcat can't find
msvcr71.dll. This appears to be a known Sun issue.
Java SE 6 applications that use custom launchers must be installed with
msvcr71.dll in the same directory as the launcher executable. This follows the new Windows C runtime distribution model, per http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_CRT_C_Run.2d.Time_Libraries.asp.
JDK_HOME\bin\msvcr71.dll to Tomcat's bin folder - or Confluence's bin folder if you are running the Standalone version.