- Learning Continuous Integration with Jenkins(Second Edition)
- Nikhil Pathania
- 131字
- 2021-07-02 21:18:38
Installing Java
Follow these steps to install Java:
- Move to the /tmp directory and download Java:
cd /tmp
wget -O java_8.131.rpm \
http://javadl.oracle.com/webapps/download/AutoDL? \
BundleId=220304_d54c1d3a095b4ff2b6607d096fa80163
- Next, install Java. The following command will install the JRE:
sudo rpm -ivh java_8.131.rpm
- To set the JAVA_HOME environment variable, first get the Java installation's location. Do this by executing the following command:
sudo alternatives --config java
- The previous command will print the list of Java applications installed on your machine, along with their installation paths. Copy the Java path that appears on your Terminal:
There is 1 program that provides 'java'. Selection Command ----------------------------------------------- *+ 1 /usr/java/jre1.8.0_131/bin/java
- Add the Java path (the one that you copied earlier) inside the /etc/environment file using the following command:
sudo sh \
-c "echo JAVA_HOME=/usr/java/jre1.8.0_131 >>
/etc/environment"
推薦閱讀
- Linux網絡管理與配置(第2版)
- 從零開始寫Linux內核:一書學透核心原理與實現
- Linux內核完全注釋(20周年版·第2版)
- Ubuntu Linux操作系統
- 精解Windows8
- Installing and Configuring Windows 10:70-698 Exam Guide
- Linux網絡內核分析與開發
- Java EE 8 Design Patterns and Best Practices
- Windows 7中文版從入門到精通(修訂版)
- Linux內核觀測技術BPF
- Fedora 12 Linux應用基礎
- 大規模分布式系統架構與設計實戰
- Multi-Cloud for Architects
- OpenVZ Essentials
- Android NDK Beginner's Guide