0

I need upgrade my jdk to the newest one.

Case in that, i have downloaded new Android Studio 2.1 and get such issue

enter image description here

if i go according to the link, i realize that my jdk version not compatible with android studio 2.1...

eventually my old jdk lie in /usr/lib/java/jdk1.8.0_65, say me please which commands i should input in order to upgrade my JDK?

Thaks for suggest

Here screenshot with synaptic

enter image description here

0

Uninstall your current java installation and do the following:

Insert the webupd8team java ppa to your system (as root):

add-apt-repository ppa:webupd8team/java

apt-get update

Install both oracle-java8-installer and oracle-java8-set-default. This will keep your JDK updated whenever new versions are released by Oracle.

  • Sorry but i am a rookie in android... Issue is that, i can't delete current installation ... I don't know why, it didn't have such properties... Maybe i should try with help of terminal, but which command? – Aleksey Timoshchenko May 13 '16 at 18:28
  • How did you make your current installation? – Stormlord May 13 '16 at 18:33
  • it was downloaded concurrently with Android Studio... – Aleksey Timoshchenko May 13 '16 at 18:47
  • That's strange. I've been using Android Studio for at least a year and the zip file I downloaded from the Android developers site never had anything other than Android studio itself. Anyway, check if you're using OpenJDK instead and if yes, you can uninstall it easily using synaptic. – Stormlord May 13 '16 at 19:22
  • Yes i use Open JDK OpenJDK Runtime Environment (IcedTea 2.6.6) (7u101-2.6.6-0ubuntu0.14.04.1) OpenJDK 64-Bit Server VM (build 24.95-b01, mixed mode) But you said it is easily uninstall, but how?(( i haven't used synaptic before... – Aleksey Timoshchenko May 13 '16 at 19:29
0

Eventually i have found solution. Issue was in this case, i were needed change the environment variable, the first open the file :

sudo nano  /etc/environment

and next step is add this line :

JAVA_HOME=(your path to JDK)

in my case was :

JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64

and all is work

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.