Tomcat None Starter With JDK7 (Win7) 1.7.7 [SOLVED]

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Tomcat None Starter With JDK7 (Win7) 1.7.7 [SOLVED]

Postby laceja » 21. October 2011 21:24

I just installed XAMPP 1.7.7 on a Windows 7 Ultimate SP 1, but I Tomcat won't start. Isn't Tomcat included in the basic package now. So, how do I start Tomcat?

Thanks!
laceja
 
Posts: 6
Joined: 12. July 2010 18:35

Re: Tomcat on XAMPP 1.7.7

Postby Altrea » 21. October 2011 21:37

1st: please add your OS-version and XAMPP version in your profile settings.
2nd: Please try out the new XAMPP control panel v3.0.4 from viewtopic.php?f=16&t=46743&start=45#p186862. It has some really nice improvements especially for Tomcat
3rd: have you installed already JRE or JDK?
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: Tomcat on XAMPP 1.7.7

Postby laceja » 21. October 2011 22:53

Thanks, I'll check out the new control panel and update my profile.

Yes, I have JDK1.7.0.01 installed and the JAVA_HOME is set for it.
laceja
 
Posts: 6
Joined: 12. July 2010 18:35

Re: Tomcat None Starter With JDK7 (Win7) 1.7.7

Postby hackattack142 » 05. November 2011 21:11

I am investigating this. I just installed the JDK 7 Update 1 with JRE 7. The batch files do pick up the JDK and use it. I am getting an exception during the server initialization. Try opening up a command prompt window (start > run > cmd), change directory to the "C:\xampp" or where ever you have xampp installed to, and try to run the "catalina_start.bat" file. This will keep the window open if the server crashes so you can see the output. Look for any Java exceptions. I am getting a "SEVERE: StandardServer.await: create[localhost:8005]" I am investigating the issue further but the port does not appear to be in use.

Update:
After some investigation, this appears to be a Java 7 issue. In Java 7 they implemented new Socket code that adds and uses IPv6. Under the hood it maps IPv4 addresses to IPv6 and this can cause issues if the application does not support those types of sockets. I am sure the Tomcat files could be edited in some fashion to get around this (haven't found it yet) but the easier solution would be to stick with Java 6 for the meantime unless there is a specific reason you never version 7. I had not upgraded because I have heard version 7 is riddled with issues and was waiting until more updates were out.

Update 2:
Figured out how to fix it.
Open "xampp/tomcat/bin/catalina.bat" and change line 310 from this:
Code: Select all
%_EXECJAVA% %JAVA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -Djava.endorsed.dirs="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_HOME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" %MAINCLASS% %CMD_LINE_ARGS% %ACTION%

to this
Code: Select all
%_EXECJAVA% %JAVA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -Djava.endorsed.dirs="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_HOME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" -Djava.net.preferIPv4Stack="true" %MAINCLASS% %CMD_LINE_ARGS% %ACTION%
XAMPP Control Panel Developer
Latest CP: viewtopic.php?f=16&t=48932
hackattack142
 
Posts: 701
Joined: 20. May 2011 23:29
Operating System: Windows 7 Ultimate SP1 64-Bit


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 122 guests