Install and configure the server version jre7 in Linux

Source: Internet
Author: User

Linux: CentOS 6.4
 
Required tools: server-jre-7u51-linux-x64.tar.gz
 
1. First download server-jre-7u51-linux-x64.tar.gz, which is available on the official Oracle website.
 
Input: wget

2, install, enter the tar zxvf server-jre-7u51-linux-x64.tar.gz To Get A jdk Plus version of a folder, move it to the directory you want to place
 
3. Input and edit environment variables: vi/etc/profile
 
Enter at the bottom:
 
JAVA_HOME =/usr/local/java/jdk7
PATH = $ JAVA_HOME/bin: $ PATH
CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar
Export JAVA_HOME
Export PATH
Export CLASSPATH

Esc-> wq save and exit
 
Enter source/etc/profile to take effect.
 
4. verify whether the installation is successful.
 
Input: if the following information is displayed in java-version, the installation is successful.
 
Java version "1.7.0 _ 51"
Java (TM) SE Runtime Environment (build 1.7.0 _ 51-b13)
Java HotSpot (TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

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.