Installation Notes
System environment: centos7 centos6.5
installation method: rpm installation
software: jdk-8u25-linux-x64.rpm
download address: http://www.oracle.com/technetwork/java/javase/downloads/index.html
Check the original version of the system
- 1
- 2
- 3
- 4
Further view JDK information:
- 1
- 2
- 3
- 4
- 5
- 6
Uninstall OpenJDK and perform the following operations:
- 1
- 2
- 3
Install JDK
Upload the new jdk-8u25-linux-x64.rpm software to /usr/local/ and perform the following operations:
[root@zck local]# rpm -ivh jdk-8u25-linux-x64.rpm
The JDK is installed in /usr/java by default.
Verify installation
Perform the following operations to check whether the information is normal:
- 1
- 2
- 3
- 4
- 5
- 6
Configure environment variables
After installing jdk-7-linux-x64.rpm on my machine, javac and java -version operations can be performed normally without configuring environment variables, so I did not configure JDK environment variables. But for future uncomfortable needs, here is still a record of how to configure, the operation is as follows:
modify the system environment variable file
vi + /etc/profile
Append the following content to the file:
The location can be placed at the end of the profile file
- 1
- 2
- 3
- 4
- 5
Make changes take effect
- 1
- 2
View system environment status
- 1
- 2
Installation Notes
System environment: centos7 centos6.5
installation method: rpm installation
software: jdk-8u25-linux-x64.rpm
download address: http://www.oracle.com/technetwork/java/javase/downloads/index.html
Check the original version of the system
- 1
- 2
- 3
- 4
Further view JDK information:
- 1
- 2
- 3
- 4
- 5
- 6
Uninstall OpenJDK and perform the following operations:
- 1
- 2
- 3
Install JDK
Upload the new jdk-8u25-linux-x64.rpm software to /usr/local/ and perform the following operations:
[root@zck local]# rpm -ivh jdk-8u25-linux-x64.rpm
The JDK is installed in /usr/java by default.
Verify installation
Perform the following operations to check whether the information is normal:
- 1
- 2
- 3
- 4
- 5
- 6
Configure environment variables
After installing jdk-7-linux-x64.rpm on my machine, javac and java -version operations can be performed normally without configuring environment variables, so I did not configure JDK environment variables. But for future uncomfortable needs, here is still a record of how to configure, the operation is as follows:
modify the system environment variable file
vi + /etc/profile
Append the following content to the file:
The location can be placed at the end of the profile file
- 1
- 2
- 3
- 4
- 5
Make changes take effect
- 1
- 2
View system environment status
- 1
- 2