How to install a second JVM?

守給你的承諾、 提交于 2020-01-03 01:56:05

问题


I am working on a Linux Ubuntu 8.10 and I would like to install a second JVM. I am currently working with Java 1.6, but I want to install Java 1.4 and afterwards, set the 1.4 JVM as my default JVM, to work with. How could I do that? Thanks in advance!


回答1:


Just install the package you want. After that you're able to switch java implementations using update-java-alternatives

See Help pages for more.




回答2:


With Linux, you can install multiple JVMs without conflict (unlike Windows, where the registry is updated).

Your "default" JVM is controlled in two ways: if you're executing java from the command line, it's the PATH environment variable. That is described in any Unix reference.

The other way is the file ${HOME}/.java/deployment/deployment.properties, which is used by Java Webstart and the Java Browser Plugin. You'll find several configuration variables in this file that refer to the version. Your safest approach is to rename the .java directory before installing an earlier version.



来源:https://stackoverflow.com/questions/751392/how-to-install-a-second-jvm

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!