0

I try to run the tomcat using ./startup.sh under bin folder. The console print out following:

Using CATALINA_BASE:   /c/Users/zzhang/Desktop/apache-tomcat-7.0.107-src
Using CATALINA_HOME:   /c/Users/zzhang/Desktop/apache-tomcat-7.0.107-src
Using CATALINA_TMPDIR: /c/Users/zzhang/Desktop/apache-tomcat-7.0.107-src/temp
Using JRE_HOME:        /c/Program Files (x86)/Common Files/Oracle/Java
Using CLASSPATH:       /c/Users/zzhang/Desktop/apache-tomcat-7.0.107-src/bin/bootstrap.jar:/c/Users/zzhang/Desktop/apache-tomcat-7.0.107-src/bin/tomcat-juli.jar
Using CATALINA_OPTS:
Tomcat started.

However when I go to localhost:8080, it shows the site can't be reached. When I check the log in catalina.out it shows following:

/c/Users/zzhang/Desktop/apache-tomcat-7.0.107-src/bin/catalina.sh: line 498: /c/Program Files (x86)/Common Files/Oracle/Java/bin/java: No such file or directory

Anyone knows how can I solve this problem?

Currently my JAVA_HOME pointing to "C:\Program Files\Java\jdk-11\"

Thanks

1 Answer 1

1

Based on you using shell scripts (files ending with ".sh") and observing Windows paths ("c:\Program Files\Java\jdk-11" I'm guessing you're using cygwin?

catalina.sh will prefer your JRE_HOME unless you run with the debug option. What is your JRE_HOME set to? If it's set, try clearing it out...

$ export JRE_HOME=""
$ startup.sh

or

$ JRE_HOME="" startup.sh
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.