Set up JSP runtime environment configuration under UbuntuLinux System Platform

Source: Internet
Author: User
1. Install the Java environment and configuration method 1: 1. Open the terminal, execute the command, install jre and jdk: $ sudoapt-getinstallsun-java6-jre; $ sudoapt-getinstallsun-java6-jdk; 2. Set the current default java interpreter: after sudoupdate-alternatives-configjava is executed, select a row containing "sun ".

1. Install the Java environment and Configuration

Method 1:
1. Open the terminal, execute the command, and install jre and jdk:

 
  1. $sudoapt-getinstallsun-java6-jre;  
  2. $sudoapt-getinstallsun-java6-jdk; 

2. Set the current default java interpreter:

 
  1. sudoupdate-alternatives-configjava 

After the command is executed, select the number in front of the row containing "sun" and press enter to confirm.

3. Configure Environment Variables

 
  1. $sudogedit/etc/environment 

Add two rows:

 
  1. CLASSPATH=/usr/lib/jvm/java-1.5.0-sun/lib  
  2. JAVA_HOME=/usr/lib/jvm/java-1.5.0-sun 

Method 2:

1. First, check whether the software required for the rpm package is installed. Run the following command on the Terminal:

$ Rpm-q-a // View

Run the software required to install rpm:
$ Sudoapt-getinstallrpm

2. Download jdk Installation Software: (you can go to the sun Website: http://java.sun.com) to the user folder.

3. Install jdk software:

In Terminal, enter./jdk software name. bin. If the Protocol appears, select agree to press y and press enter to start installation. After installation, the folder name is jdk1.6.0 _ 01.

4. Create a JDK Link

 
  1. $ln-sjdk1.6.0.0_01jdk 

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.