0

So the application DHIS2 runs only in Java-version-8, while many applications are still not compatible with newer Java Version. In such condition how can I run two different applications at same time? Can I manually specify the location of openjdk? Or are their any alternatives to switch the java variables?

Thanks in advance

Cheers

sigdelsanjog
  • 7,110
  • 1
    What do you mean with “not compatible with newer java version“? Have you tried? Compatibility problems like that are extremely rare with java. – Axel Jan 27 '16 at 06:11

1 Answers1

1

You can do it easily, just run it specifying the path of java you want to use.

In details:

Normally java is installed under /usr/lib/jvm there where you can find the default java versions you have in your system.

So if you want to run another version other than the default one you should specify the full path of the Java.

for example suppose that java-version-8 as you specified above is under your Desktop so you can run any app using this version with the command:

~/Desktop/java-version-8/java /path-to-your-application

so you indicate what version to use.

If you want to do it GUI you can create a .desktop or edit an existing .desktop for the app to specify the path of the new-java instead of the default one.

Read this and this to learn how to use .desktop files

Maythux
  • 84,289