Tomcat使用哪个Java版本 [英] which java version does tomcat use

查看:77
本文介绍了Tomcat使用哪个Java版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已将 JAVA_HOME 设置为 C:\ Program Files \ Java \ jdk1.5.0_11
我已经将 Classpath 设置为 C:\ Program Files \ Java \ jre1.5.0_11

I have set the JAVA_HOME to C:\Program Files\Java\jdk1.5.0_11
I have set the Classpath to C:\Program Files\Java\jre1.5.0_11

我已将路径设置为

C:\ Ruby193 \ bin; C:\ XEClient \ bin;F:\ oracle \ product \ 10.2.0 \ db_2 \ bin;%SystemRoot%\ system32;%SystemRoot%;%SystemRoot%\ System32 \ Wbem;C:\ Program Files \ Java \ jdk1.6.0_17 \ bin;C:\ Program Files \ jEdit; C:\ Program Files \ TortoiseSVN \ bin;C:\ Program Files \ Microsoft SQL Server \ 90 \ Tools \ binn \

现在我的问题是,tomcat在什么Java版本上运行?
tomcat控制台写入整个路径"
并且 cmd 表示它是系统中当前正在运行的Java版本7.
有人请帮帮我..我的系统中安装了Java 5,6,7版本,同时也安装了tomcat 5,6,7.
现在什么是tomcat的java版本和系统的java版本???

Now my question is, what version of java does the tomcat run on?
The tomcat console writes the whole 'path'
and the cmd says it is java version 7 currently running in the system.
Someone please help me out.. I have java 5,6,7 versions installed in my system and also tomcat 5,6,7.
Now what is the tomcat's java version and the system's java version???

推荐答案

您可以在默认情况下安装的管理器应用中查找 Tomcat实际运行的Java版本.转到 http://hostname:8080/manager/html (用主机名或localhost替换主机名),滚动到底部,您将在其中找到"JVM版本".

You can look up the Java version Tomcat is really running with in the manager app, which is installed by default. Go to http://hostname:8080/manager/html (replace hostname by hostname or localhost), scroll to the bottom, there you will find "JVM Version".

选择哪个JVM 很大程度上取决于操作系统和安装方式,也许

Which JVM is selected depends a lot on the OS and way to install, maybe http://tomcat.apache.org/tomcat-7.0-doc/setup.html will help.

例如如果您正在运行带有带有服务包装程序的Tomcat的Windows (我建议在Windows中使用它),则可以直接在任务栏图标->配置中设置JVM的路径雄猫.在Java标签中将Java虚拟机设置为"D:\ java \ jdk1.6.0_35 \ jre \ bin \ server \ jvm.dll"(禁用使用默认值")或JVM驻留的位置->您需要指定jvm的完整路径.dll.

E.g. if you are running Windows with Tomcat with the service wrapper (I would recommend this for Windows), you can set the path to the JVM directly in the tray icon -> Configure Tomcat. In the Java tab e.g. set Java Virtual Machine to "D:\java\jdk1.6.0_35\jre\bin\server\jvm.dll" (disabled "use default") or where your JVM resides -> you need to specify the complete path to the jvm.dll.

关于系统正在运行哪个Java :这很难回答,实际上并没有一个Java版本可以运行该系统.例如.对于Windows,可能在PATH中设置了一个Java版本,在JAVA_HOME/JRE_HOME/...中可能设置了一个不同的版本,在注册表中设置了一个(或多个)版本,在每个用于applet的Web浏览器中都激活了某个版本的插件等.您必须检入您感兴趣的部分.大多数优秀的Java应用程序都会在日志,关于对话框等内容的某个位置显示使用的版本.对于Firefox,您可以签入加载项/插件列表.像JSmooth这样的Java exe包装器可以在不同的地方搜索Java并选择最合适的,例如最新的,不一定是最暴露的".

Regarding getting to know which Java the system is running on: That's difficult to answer, there isn't really one Java version that the system is running as such. E.g. for Windows there may be one Java version set in the PATH, a potentially different one in JAVA_HOME / JRE_HOME / ..., one (or more) set in the registry, a certain version plugin active in each web browser used for applets etc. You have to check in the part you are interested in. Most good Java apps will display the version used somewhere, in logs, about dialogs or so. For Firefox you can check in the add-ons / plug-ins list. A Java exe wrapper like JSmooth can search for Java in different places and choose the most suitable, e.g. the newest, not necessarily the most "exposed".

这篇关于Tomcat使用哪个Java版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆