- Mastering Apache Storm
- Ankit Jain
- 136字
- 2021-07-02 20:32:28
Installing Java SDK 7
Perform the following steps to install the Java SDK 7 on your machine. You can also go with JDK 1.8:
- Download the Java SDK 7 RPM from Oracle's site (http://www.oracle.com/technetwork/java/javase/downloads/index.html).
- Install the Java jdk-7u<version>-linux-x64.rpm file on your CentOS machine using the following command:
sudo rpm -ivh jdk-7u<version>-linux-x64.rpm
- Add the following environment variable in the ~/.bashrc file:
export JAVA_HOME=/usr/java/jdk<version>
- Add the path of the bin directory of the JDK to the PATH system environment variable to the ~/.bashrc file:
export PATH=$JAVA_HOME/bin:$PATH
- Run the following command to reload the bashrc file on the current login terminal:
source ~/.bashrc
- Check the Java installation as follows:
java -version
The output of the preceding command is as follows:
java version "1.7.0_71" Java(TM) SE Runtime Environment (build 1.7.0_71-b14) Java HotSpot(TM) 64-Bit Server VM (build 24.71-b01, mixed mode)
推薦閱讀
- 認識編程:以Python語言講透編程的本質
- Learning C++ Functional Programming
- NumPy Essentials
- 實戰Java高并發程序設計(第3版)
- Learning Network Forensics
- Oracle 18c 必須掌握的新特性:管理與實戰
- Android程序設計基礎
- D3.js By Example
- Django 5企業級Web應用開發實戰(視頻教學版)
- ASP.NET 4.0 Web程序設計
- 程序員的成長課
- Learning Unreal Engine Game Development
- After Effects CC技術大全
- Java程序設計實用教程(第2版)
- Access數據庫應用教程(2010版)