Running the wrong version of Java [message #1835586] |
Mon, 07 December 2020 11:45  |
Eclipse User |
|
|
|
When I try to run tomcat 8.0.53 in eclipse as the server, it will not start because it is looking for java at:
INFO: Java Home: /usr/share/jdk-13.0.2
I have JAVA_HOME set to /usr/share/jdk1.8.0_261.
I have been looking through eclipse IDE and have yet to find any place where jdk-13.0.2 is mentioned. (BTW I do have jdk13 installed at /usr/share/jdk-13.0.2).
I have also looked at the eclipse.ini file and did not see jdk-13.0.2 referenced.
Can someone explain how sync up Eclipse with my environment variable $JAVA_HOME? Or where the java home gets set in Eclipse?
Jim A.
|
|
|
|
Re: Running the wrong version of Java [message #1835589 is a reply to message #1835587] |
Mon, 07 December 2020 13:19   |
Eclipse User |
|
|
|
--> "In your Servers/Runtime Environments preference page"
First off, thank you for your response.
If I go to the tab labeled 'Servers', I have Tomcat 8 and 9. For now, I am ignoring Tomcat 9.0 and I am working with Tomcat 8.0.85. If I right click on Tomcat server 8.0, and select preferences, a page pops titled "Properties for Tomcat v8.0 Server at localhost", but there is no indication there for what JRE is being used.
I also tried a right click on 'Servers' in Project Explorer, followed by selecting 'Properties'. That popped up a page named, "Properties for Servers", but I could not find a reference to a JRE there either.
I suspect you mean a different preference page, but as yet, I have not found it. I'm sorry to ask for more specific instructions, but I am not sure where else to try. Can you give an addition pointer?
Jim A.
|
|
|
Re: Running the wrong version of Java [message #1835594 is a reply to message #1835589] |
Mon, 07 December 2020 17:34  |
Eclipse User |
|
|
|
On the Window menu (or the application menu on macOS), you'll find an action to open the Preferences dialog. Servers is a category
there, and within it, there is a page called Runtime Environments. Don't confuse this with the contents of the Servers View that you
mentioned. The preference page sets up the runtimes on their own--which version it is, where it's located, and which JRE is used. What
you're seeing in the view are different instances of that runtime, each potentially configured with different JNDI resources, applications,
and port numbers. You always need at least one instance to actually run your application, but you can make more if you want.
You can also get there using Find Actions with Ctrl+3 or Cmd+3 and searching for "Runtimes".
[Updated on: Mon, 07 December 2020 17:38] by Moderator
|
|
|
Powered by
FUDForum. Page generated in 0.09021 seconds