Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I setup the tomcat7 as a service as below:

c:\Program Files (x86)\Tomcat7\apache-tomcat-7.0.32\bin>service.bat install
Installing the service 'Tomcat7' ...
Using CATALINA_HOME:    "C:\Program Files (x86)\Tomcat7\apache-tomcat-7.0.32"
Using CATALINA_BASE:    "C:\Program Files (x86)\Tomcat7\apache-tomcat-7.0.32"
Using JAVA_HOME:        "C:\Program Files (x86)\Java\jdk1.7.0_09"
Using JRE_HOME:         "C:\Program Files (x86)\Java\jdk1.7.0_09\jre"
Using JVM:              "C:\Program Files (x86)\Java\jdk1.7.0_09\jre\bin\server\
jvm.dll"

However, when I try to start the service, I Get the error below:

c:\Program Files (x86)\Tomcat7\apache-tomcat-7.0.32\bin>tomcat7.exe
%1 is not a valid Win32 application.
Failed to run service as console application

This is the file I downloaded from apache: apache-tomcat-7.0.32-windows-x64.zip. I am able to successfully start tomcat on port 8080 as a standalong thing. Meaning I go to command prompt and type startup.bat and it starts up successfully.

Question

How can I resolve this and what are the things I should be troubleshooting for?

share|improve this question
    
You should start the service from the services console, not the command line. –  Chris McKeown Nov 6 '12 at 13:01
    
Dear @Birdy - it sounds like you're working for a large financial services company in Sydney. Perhaps the magic pixies there have looked at this over the weekend. –  Hawkeye Feb 10 '13 at 4:25
add comment

2 Answers

There is a post on the sister site that might help you. Here is the link: http://stackoverflow.com/questions/5920051/installing-tomcat-7-as-service-on-windows-server-2008

share|improve this answer
add comment

As a clue to your next step - on the command line run

java -version

(Which should say 32 bit... blah blah).

Now you're installing the 64 bit version of Tomcat.

Perhaps you'd consider installing the 64 bit version of the JDK.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.