WebHosting

Tuesday, April 24, 2012

How to set alternative java : set default java to use in linux

Start terminal (ctrl+alt+t) and type the following command :



sudo update-alternatives --config java



This will print option as follows :



  Selection    Path                                      Priority   Status
------------------------------------------------------------
* 0            /usr/lib/jvm/java-6-openjdk/jre/bin/java   1061      auto mode
  1            /usr/lib/jvm/java-6-openjdk/jre/bin/java   1061      manual mode
  2            /usr/lib/jvm/java-6-sun/jre/bin/java       63        manual mode


Press enter to keep the current choice[*], or type selection number: 2

And here you can select option giving 0/1/2 to set the default java to use. :) cheer :)

No comments:

Post a Comment

Thank you for Commenting Will reply soon ......

Featured Posts

Error Message in DBeaver connecting using jdbc: Public Key Retrieval is not allowed

Fixing “Public Key Retrieval is not allowed” Error in MySQL with DBeaver   If you are trying to connect MySQL 8+ with DBeaver and suddenly...