Home PC Games Linux Windows Database Network Programming Server Mobile  
  Home \ Linux \ JDK installation under CentOS     - CentOS 6.5 install Firefox (Linux)

- Oracle 10g after the failure to start the upgrade (Oracle instance terminated. Disconnection forced) (Database)

- To install Gitolite in Ubuntu / Fedora / CentOS (Linux)

- OpenDaylight Helium version installed (Linux)

- The source code compiler installation Nginx 1.8.0 under Ubuntu 14.10 (Server)

- How to choose the first programming language based on the life you want (Programming)

- CentOS6 install Redis (Database)

- To install CentOS 6.5 on your hard drive under Windows 7 (Linux)

- Hadoop safe hftp (Server)

- Ubuntu modify locale problem solving (Linux)

- The correct way to open Xcode - Debugging (Programming)

- Linux process management related content (Linux)

- The difference between free command displays the buffers and cache (Linux)

- SQLite (Database)

- Go constructed using an interpreted language (Programming)

- Java Adapter Mode (Programming)

- Android Touch message passing mechanism analysis (Programming)

- Based on Python: OpenCV simple image manipulation (Programming)

- See how --nand flash timing diagram of a read operation Comments (Programming)

- ADSL router to defend their own network security methods (Linux)

  JDK installation under CentOS
  Add Date : 2017-02-07      
  Under CentOS JDK installation

Installation: rpm installation
Software: jdk-7-linux-x64.rpm

The original version of the inspection system

[Root @ abctest~] # java -version

java version "1.6.0_24"

OpenJDK Runtime Environment (IcedTea6 1.11.1) (rhel-

OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

See JDK further information:

[Root @ abctest~] # rpm -qa | grep java



Uninstall OpenJDK, do the following:

[Root @ abctest~] # rpm -e --nodeps tzdata-java-2012c-1.el6.noarch

[Root @ abctest~] # rpm -e --nodeps java-1.6.0-openjdk-

Install the JDK

Upload a new jdk-7-linux-x64.rpm software to the / usr / local / perform the following actions:

[Root @ abctestlocal] # rpm -ivh jdk-7-linux-x64.rpm

JDK is installed by default in / usr / java in.

Verifying the Installation

Do the following to view the information properly:

[Root @ abctest bin] # java

[Root @ abctest bin] # javac

[Root @ abctest bin] # java -version

java version "1.7.0"

Java (TM) SE Runtime Environment (build 1.7.0-b147)

Java HotSpot (TM) 64-Bit Server VM (build 21.0-b17, mixed mode)

Congratulations, the installation was successful!

Configuration environment variable

I do not have to configure the environment variable machine installing jdk-7-linux-x64.rpm can also perform normal javac, java -version operation, so I do not have to configure JDK environment variable. But the need for future discomfort, here is the record about how to configure, operate as follows:

Modify system environment variables file

vi + / etc / profile

Append the following to the file contents inside:

JAVA_HOME = / usr / java / jdk1.7.0

JRE_HOME = / usr / java / jdk1.7.0 / jre

PATH = $ PATH: $ JAVA_HOME / bin: $ JRE_HOME / bin

CLASSPATH =:. $ JAVA_HOME / lib / dt.jar: $ JAVA_HOME / lib / tools.jar: $ JRE_HOME / lib


Changes to take effect

 [Root @ abctest local] # source / etc / profile // changes to take effect immediately

[Root @ abctest local] # echo $ PATH // View PATH value

View system environmental status

[Root @ abctest ~] # echo $ PATH

/usr/local/cmake/bin:/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin: /usr/java/jdk1.7.0/bin:/usr/java/jdk1.7.0/jre/bin:/root/bin
- Nginx + uWSGI + Django + Python Application Architecture Deployment (Server)
- Java 8 Lambda principle analysis (Programming)
- Protection Docker container Notice (Server)
- vector C ++ sequence containers (Programming)
- Incremental garbage collection mechanism for Ruby 2.2 (Programming)
- Ambari and Hadoop configuration, management and monitoring of the project Getting (Server)
- Use XtraBackup to MySQL database online incremental backup and recovery (Database)
- SecureCRT 7.0 Log Ubuntu 12.04 server via SSH service under Vmware (Server)
- Good wireless network security information spread in the air (Linux)
- Use Oracle 11g show spparameter command (Database)
- Ubuntu 14.10 / 14.04 / 12.04 installation GNOME Pie 0.5.6 (Linux)
- Linux kernel netpoll framework netconsole (Linux)
- HTTPS and SSH and use the difference between the way: Git User's Manual (Linux)
- CentOS 6.4 under PXE + Kickstart unattended operating system installation (Programming)
- Compiled version of Android Opus audio codec library method (Programming)
- 29 practical examples Linux system / network administrator of nmap (Linux)
- Lua4.0 interpreter entrance (Programming)
- OpenSSL for secure transmission and use of skills of files between Windows and Linux (Linux)
- Linux log management tools Logrotate (Linux)
- Introduction and use of the Raspberry Pi (Linux)
  CopyRight 2002-2022 newfreesoft.com, All Rights Reserved.