From Documentation
Jump to: navigation, search
(Trouble Shooting)
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
{{Template:CCDelete}}
 
{{Software
 
{{Software
 
|package_name=OPENJDK
 
|package_name=OPENJDK
Line 4: Line 5:
 
|package_idnumber=66
 
|package_idnumber=66
 
}}
 
}}
 +
{{Template:GrahamUpdate}}
  
 
=Introduction=
 
=Introduction=
Line 12: Line 14:
 
=Deployment=
 
=Deployment=
 
There are a number of ways that your program might be deployed onto a SHARCNET cluster: pre-installed software, as a RPM file, as a JAR file, or from source.  Supported software, found [[https://www.sharcnet.ca/my/software/index here]], has an staff member assigned to support it and does not require deployment.  An RPM package, typically available with a complete software platform, will have the steps prepared and typically involve more than just the Java environment.  The remainder of this article will deal with the last two options, installing from java ARchive (JAR) files or directly from source.
 
There are a number of ways that your program might be deployed onto a SHARCNET cluster: pre-installed software, as a RPM file, as a JAR file, or from source.  Supported software, found [[https://www.sharcnet.ca/my/software/index here]], has an staff member assigned to support it and does not require deployment.  An RPM package, typically available with a complete software platform, will have the steps prepared and typically involve more than just the Java environment.  The remainder of this article will deal with the last two options, installing from java ARchive (JAR) files or directly from source.
 +
 +
==Java 8==
 +
The following systems have Java 8 installed located at '/usr/lib/jvm/java-1.8.0-openjdk.x86_64/bin' this can be added to your path in your .bashrc file.<br>
 +
Systems: angel, brown, copper, goblin, hound, iqaluk, kraken, mako, mosaic, orca, redfin, saw, tembo, vdi-centos6, windeee, wobbie. <br>
  
 
==JAR files==
 
==JAR files==
Line 18: Line 24:
 
==Compilation==
 
==Compilation==
  
=Executing=
+
=Executing With SQSUB=
 +
The Java Virtual Machine (JVM) with standard settings requires a minimum of about 4GB to execute. The JVM adds the heap memory on top of this, thus requiring more than 4GB. You need to limit the size of the heap in the JVM at the same time as requesting more memory from our scheduler. If you don't do this the JVM will use all available memory and a memory error will occur. Normally, because of virtual memory, this isn't a problem. However, due to our scheduler you get allocated a 1:1 ratio of physical:virtual memory. Memory is requested from our scheduler with the --mpp command from sqsub. To limit the heap size you use the -Xmx command in java.
 +
An example is: sqsub -r 6h --mpp=6G java -Xmx2G yourprogram.jar
  
 
=Trouble Shooting=
 
=Trouble Shooting=

Latest revision as of 09:23, 6 June 2019

This page is scheduled for deletion because it is either redundant with information available on the CC wiki, or the software is no longer supported.
OPENJDK
Description: Open source implementation of Java SE.
SHARCNET Package information: see OPENJDK software page in web portal
Full list of SHARCNET supported software


Note: Some of the information on this page is for our legacy systems only. The page is scheduled for an update to make it applicable to Graham.


Introduction

Java is a general-purpose, object-oriented language which is designed to have few platform dependencies. Both the runtime environment and development tools are installed on SHARCNET clusters. The purpose of this article is to assist the user in deploying, executing, and trouble shooting Java programs on SHARCNET.

Related Pages

Deployment

There are a number of ways that your program might be deployed onto a SHARCNET cluster: pre-installed software, as a RPM file, as a JAR file, or from source. Supported software, found [here], has an staff member assigned to support it and does not require deployment. An RPM package, typically available with a complete software platform, will have the steps prepared and typically involve more than just the Java environment. The remainder of this article will deal with the last two options, installing from java ARchive (JAR) files or directly from source.

Java 8

The following systems have Java 8 installed located at '/usr/lib/jvm/java-1.8.0-openjdk.x86_64/bin' this can be added to your path in your .bashrc file.
Systems: angel, brown, copper, goblin, hound, iqaluk, kraken, mako, mosaic, orca, redfin, saw, tembo, vdi-centos6, windeee, wobbie.

JAR files

A JAR file may be an "executable JAR file" which allow you to execute the program directly from the JAR file.

Compilation

Executing With SQSUB

The Java Virtual Machine (JVM) with standard settings requires a minimum of about 4GB to execute. The JVM adds the heap memory on top of this, thus requiring more than 4GB. You need to limit the size of the heap in the JVM at the same time as requesting more memory from our scheduler. If you don't do this the JVM will use all available memory and a memory error will occur. Normally, because of virtual memory, this isn't a problem. However, due to our scheduler you get allocated a 1:1 ratio of physical:virtual memory. Memory is requested from our scheduler with the --mpp command from sqsub. To limit the heap size you use the -Xmx command in java. An example is: sqsub -r 6h --mpp=6G java -Xmx2G yourprogram.jar

Trouble Shooting

Error Message: Unsupported major.minor version 52.0
Cause: You are attempting to execute a java program on a different version JRE than it was compiled on. Often seen when running a Java 8 program on SHARCNET which is set up with Java 7.
Fix: Install the Java 8 (or appropriate version) in your home directory. To install Java 8, perform the following steps.

The following systems have Java 8 installed located at '/usr/lib/jvm/java-1.8.0-openjdk.x86_64/bin' this can be added to your path in your .bashrc file.
Systems: angel, brown, copper, goblin, hound, iqaluk, kraken, mako, mosaic, orca, redfin, saw, tembo, vdi-centos6, windeee, wobbie.