Oracle JDK安装了两个JRE? [英] Oracle JDK installs two JREs?

查看:176
本文介绍了Oracle JDK安装了两个JRE?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在downvoting之前关闭请求这个问题请看这个问题是关于JDK 7而不是6,它有第二个问题'Q2'没有解决任何重复的线程,这个问题是关于不仅两个 java.exe实例。谢谢!

Before downvoting or close-requesting this question please see that this question is about JDK 7 not 6, it has a second question 'Q2' which is not addressed by any duplicate thread and this question is about four not only two java.exe instances. Thank you!

我刚刚安装了Oracle的Java SE JDK(64位),导致了以下目录布局,并以某种方式两个 JRE:

I've just installed Oracle's Java SE JDK (64 bit) which resulted in the following directory layout, and somehow two JREs:

C:\Program Files\Java\
    \jdk1.7.0_40
        \jre
    \jre7

我现在是 java.exe 可执行文件的自豪拥有者:

I'm now the proud owner of four java.exe executables:

C:\Program Files\Java\jdk1.7.0_40\bin\java.exe
C:\Program Files\Java\jdk1.7.0_40\jre\bin\java.exe
C:\Program Files\Java\jre7\bin\java.exe
C:\Windows\System32\java.exe

Q1:我应该在搜索路径中放入哪一个执行基于Java的应用程序?

Q1: Which one should I put into my search path to execute Java-based applications?

Q2:我是否需要将无限制JCE策略文件放入corr的安全子目录中在我的搜索路径中或者为了正常工作而在所有其他路由中使用JRE?

Q2: Do I need to put the Unlimited JCE Policy files just into the security sub-directory of the corresponding JRE in my search path or also into all others in order to work correctly?

推荐答案

安装JDK时你会有一份副本自动安装JRE。您无需单独安装JRE副本。但这将是你的目录结构。

While installing JDK you will have a copy of JRE installed automatically. You need not install a copy of JRE separately. yet this will be your directory structure.

JDK文件夹中的JRE副本是JRE的私有副本。

The copy of JRE in the JDK folder is for the is a private copy of JRE.

安装JDK会安装私有Java SE运行时环境(JRE)和可选的公共副本。私有JRE需要运行JDK附带的工具。它没有注册表设置,完全包含在jre目录中(通常位于C:\Program Files \ _jdk1.6.0 \ jre),其位置仅为JDK所知。另一方面,公共JRE可以被其他Java应用程序使用,包含在JDK之外(通常位于C:\Program Files \ Java \ jre1.6.0),在Windows注册表中注册(在HKEY_LOCAL_MACHINE \\ \\ SOFTWARE \ JavaSoft),可以使用添加/删除程序删除,可能会也可能不会在浏览器中注册,并且可能会也可能不会将java.exe复制到Windows系统目录(使其成为默认的系统Java平台) )。

Installing the JDK installs a private Java SE Runtime Environment (JRE) and optionally a public copy. The private JRE is required to run the tools included with the JDK. It has no registry settings and is contained entirely in a jre directory (typically at C:\Program Files\jdk1.6.0\jre) whose location is known only to the JDK. On the other hand, the public JRE can be used by other Java applications, is contained outside the JDK (typically at C:\Program Files\Java\jre1.6.0), is registered with the Windows registry (at HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft), can be removed using Add/Remove Programs, might or might not be registered with browsers, and might or might not have java.exe copied to the Windows system directory (making it the default system Java platform or not)."

这篇关于Oracle JDK安装了两个JRE?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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