Install JDK 7 on centos 6.3

Source: Internet
Author: User

(1) download the jdk-7u7-linux-i586.rpm, link: Buy.

(2) Configure Environment Variables

VI/etc/profile

Press the I key to enter the insert mode, and add the following paragraph to the end of the file:

Export java_home =/usr/Java/jdk1.7.0 _ 07

Export classpath =.: $ java_home/JRE/lib/RT. jar: $ java_home/lib/dt. jar: $ java_home/lib/tools. Jar

Export Path = $ path: $ java_home/bin

Press ESC to exit insert mode and enter command mode. Then enter ": WQ" and press enter to exit.

(3) terminal input: Java-version, the following information is displayed:

Java version "1.7.0 _ 07"
Java (TM) se Runtime Environment (build 1.7.0 _ 07-b10)
Java hotspot (TM) Client VM (build 23.3-b01, mixed mode, sharing)

The installation is successful..

Related Article

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.