Difference between revisions of "SUNScholar/Prepare Ubuntu/S03"

From Libopedia
Jump to navigation Jump to search
 
(57 intermediate revisions by one other user not shown)
Line 1: Line 1:
 
<center>
 
<center>
'''[[SUNScholar/Prepare Ubuntu|Prepare Ubuntu - Index]]'''
+
  '''[[SUNScholar/Prepare Ubuntu/S04|NEXT - STEP 4]]'''
 
</center>
 
</center>
 +
==Step 3. Install the Java software dependencies==
 +
===PLEASE NOTE:===
 +
<font color="red">
  
==Step 3. Install Java Software Dependencies==
+
*'''When using "tasksel" during the Ubuntu server installation, and selecting Tomcat as an installation option, the "default-jre" was installed.'''
'''<font color="red">Please ensure you have enabled the [[SUNScholar/Install_Ubuntu/S04#Setup_the_software_repositories|Ubuntu partner repositories]] before continuing.</font>'''
+
*'''Please ensure you have enabled the [[SUNScholar/Install_Ubuntu/S04#Setup_the_software_repositories|Ubuntu partner repositories]] before continuing.'''
==Step 3.1: Install SUN Java 6 Run Time==
+
*'''If using Ubuntu 12.04 LTS and DSpace versions => 4.2, then check the following:'''
 +
http://wiki.lib.sun.ac.za/index.php/SUNScholar/Upgrading/DSpace/Release_Notes/4.X#Java_Version_Upgrade
 +
 
 +
</font>
 +
 
 +
===Step 3.1: Install Java===
 
Type as follows:
 
Type as follows:
  
  sudo apt-get install sun-java6-jre sun-java6-jdk
+
  sudo apt-get install default-jdk default-jre
 +
 
 +
List the Java alternatives by typing as follows:
 +
sudo update-java-alternatives -l
 +
 
 +
Depending on which version of the Ubuntu server you use, you should get something like the following:
 +
====Ubuntu 16.04====
 +
java-1.8.0-openjdk-amd64      1081      /usr/lib/jvm/java-1.8.0-openjdk-amd64
  
Afterwards make it available system wide:
+
====Ubuntu 14.04====
 +
java-1.7.0-openjdk-amd64 1051 /usr/lib/jvm/java-1.7.0-openjdk-amd64
  
sudo update-java-alternatives -v -s java-6-sun
+
====Ubuntu 12.04====
The screen output should be something like the following.
 
 
<pre>
 
<pre>
resetting java alternatives
+
java-1.6.0-openjdk-amd64 1061 /usr/lib/jvm/java-1.6.0-openjdk-amd64
update-alternatives: using /usr/bin/gij-4.4 to provide /usr/bin/java (java) in auto mode.
+
java-6-sun 63 /usr/lib/jvm/java-6-sun
update-alternatives: using /usr/bin/gkeytool-4.4 to provide /usr/bin/keytool (keytool) in auto mode.
 
update-alternatives: error: no alternatives for mozilla-javaplugin.so.
 
update-alternatives: using /usr/bin/gorbd-4.4 to provide /usr/bin/orbd (orbd) in auto mode.
 
update-alternatives: using /usr/bin/grmid-4.4 to provide /usr/bin/rmid (rmid) in auto mode.
 
update-alternatives: using /usr/bin/grmiregistry-4.4 to provide /usr/bin/rmiregistry (rmiregistry) in auto mode.
 
update-alternatives: error: no alternatives for xulrunner-1.9-javaplugin.so.
 
update-alternatives: using /usr/lib/jvm/java-6-sun/jre/bin/java to provide /usr/bin/java (java) in manual mode.
 
update-alternatives: using /usr/lib/jvm/java-6-sun/jre/bin/keytool to provide /usr/bin/keytool (keytool) in manual mode.
 
update-alternatives: using /usr/lib/jvm/java-6-sun/jre/bin/orbd to provide /usr/bin/orbd (orbd) in manual mode.
 
update-alternatives: using /usr/lib/jvm/java-6-sun/jre/bin/rmid to provide /usr/bin/rmid (rmid) in manual mode.
 
update-alternatives: using /usr/lib/jvm/java-6-sun/jre/bin/rmiregistry to provide /usr/bin/rmiregistry (rmiregistry) in manual mode.
 
update-alternatives: error: no alternatives for mozilla-javaplugin.so.
 
update-alternatives: error: no alternatives for xulrunner-1.9-javaplugin.so.
 
 
</pre>
 
</pre>
:;Note. Do not worry about error messages as long as the main "java" link is ok.
+
;Screenshot
 
+
[[File:Sunscholar-java.png|border]]
Check the alternative by typing as follows:
 
sudo update-java-alternatives -l
 
You should get the following
 
java-6-sun 63 /usr/lib/jvm/java-6-sun
 
  
==Step 3.2: Install Java Ant Compiler==
+
===Step 3.2: Install Ant===
 
Type as follows:
 
Type as follows:
  
 
  sudo apt-get install ant ant-optional
 
  sudo apt-get install ant ant-optional
  
  '''[[SUNScholar/Prepare Ubuntu/S02|PREVIOUS]]'''
+
<center>
 +
'''[[SUNScholar/Prepare Ubuntu/S02|PREVIOUS - STEP 2]]'''
 +
</center>
  
  '''[[SUNScholar/Prepare Ubuntu/S04|NEXT]]'''
+
[[Category:Installation]]
 
__NOTOC__
 
__NOTOC__
__NOEDITSECTION__
 

Latest revision as of 14:07, 30 October 2019

 NEXT - STEP 4

Step 3. Install the Java software dependencies

PLEASE NOTE:

  • When using "tasksel" during the Ubuntu server installation, and selecting Tomcat as an installation option, the "default-jre" was installed.
  • Please ensure you have enabled the Ubuntu partner repositories before continuing.
  • If using Ubuntu 12.04 LTS and DSpace versions => 4.2, then check the following:
http://wiki.lib.sun.ac.za/index.php/SUNScholar/Upgrading/DSpace/Release_Notes/4.X#Java_Version_Upgrade

Step 3.1: Install Java

Type as follows:

sudo apt-get install default-jdk default-jre

List the Java alternatives by typing as follows:

sudo update-java-alternatives -l

Depending on which version of the Ubuntu server you use, you should get something like the following:

Ubuntu 16.04

java-1.8.0-openjdk-amd64       1081       /usr/lib/jvm/java-1.8.0-openjdk-amd64

Ubuntu 14.04

java-1.7.0-openjdk-amd64 1051 /usr/lib/jvm/java-1.7.0-openjdk-amd64

Ubuntu 12.04

java-1.6.0-openjdk-amd64 1061 /usr/lib/jvm/java-1.6.0-openjdk-amd64
java-6-sun 63 /usr/lib/jvm/java-6-sun
Screenshot

Sunscholar-java.png

Step 3.2: Install Ant

Type as follows:

sudo apt-get install ant ant-optional
PREVIOUS - STEP 2