Install Java EE on Ubuntu

Source: Internet
Author: User
Tags glassfish
Document directory
  • Java EE 6 Development Kit bundles with JDK

JDK relationship between javaee and javase

Java EE is actually an extension of javase, which contains some class libraries for web development, such as Servlet and JSP.

Therefore, we need to first install javase for javaee, but now Oracle directly provides the package download of javaee + javase + glassfish.

Http://www.oracle.com/technetwork/java/javaee/downloads/index.html

Look down and find

Java EE 6 Development Kit bundles with JDK

This line of big text contains the following:

Schemdes:

JDK 7 update 7

Glassfish server open source edition 3.1.2.2

Java EE 6 code samples

Java EE 6 API documentation

Java EE 6 tutorial

Your first cup: An Introduction to the Java EE platform

Install the sh file as follows: Download the sh file and su it to the root user.

Chmod + x java_ee_sdk-6u4-jdk7-linux.sh

/Java_ee_sdk-6u4-jdk7-linux.sh

A Gui installation interface will pop up later. You can finish the installation by following the steps.

Finally, configure the environment variable, edit the/etc/profile file, and add the following to the end.

Java_home =/usr/local/glassfish3/jdk7
Path = $ java_home/bin: $ path
Classpath =.: $ java_home/lib/dt. jar: $ java_home/lib/tools. Jar
Export java_home
Export path
Export classpath

Explain the meanings of these variables

Java_home: JDK root directory for convenience

Path: directory of the Java command, such as Java and javac. The colon ":" Is a separator, indicating that there are multiple values, the $ PATH directory XXX: $ path will be searched in the order of separation when the command is executed. It indicates the value of the PATH variable before the path value of this line.

Classpath: directory of the Java class library. Note that there are three values, the first one is ., indicates to find the current directory (for Java projects) and the second DT. jar is the third tool of some swing beaninfo (which seems to be related to writing GUI. jar files contain Java, javac, javadoc, and other class libraries.

Then you can directly use the Java command in the shell After configuring the configuration.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.