How to Install Java jdk in arch linux – Easy way to Install new verison Java

How to Install Java jdk on Arch Linux

Hello friend’s, In this article we are going to learn how to install Java jdk Arch Linux (Install java on Arch Linux). I am going to give some simple steps to install Java jdk Arch Linux (Install java jdk on Arch Linux) in an easy way

First of all, You have to update your Arch Linux system using the command below:

sudo pacman -Syyu

Install Yaourt after updating your Arch Linux system. To install Java you have to install Yaourt because it is easy to install Java using yaourt. Just install this Yaourt from below link.

How to install Yaourt on Arch Linux

Install Java jdk Arch Linux (Install Java jdk on Arch Linux)

Java is a programming language originally developed by Sun Micro-system and released in 1995 as a core component of Sun Micro-systems’ Java platform. The language derives much of its syntax from C and C++ but has a simpler object model and fewer low-level facilities.

I’m working on Arch Linux so now I’m gonna show you how to install Oracle Java (JDK).

1. Open Terminal

Search available Oracle Java versions using the command below:

yaourt jdk

Sample output

[ashwin@archlinux ~]$ yaourt jdk
1 extra/jdk7-openjdk 7.u151_2.6.11-1
OpenJDK Java 7 development kit
2 extra/jdk8-openjdk 8.u144-1
OpenJDK Java 8 development kit
3 extra/jdk9-openjdk 9.u181-4 [installed]
OpenJDK Java 9 development kit
4 extra/jre7-openjdk 7.u151_2.6.11-1
OpenJDK Java 7 full runtime environment
5 extra/jre7-openjdk-headless 7.u151_2.6.11-1
OpenJDK Java 7 headless runtime environment
6 extra/jre8-openjdk 8.u144-1
OpenJDK Java 8 full runtime environment
7 extra/jre8-openjdk-headless 8.u144-1
OpenJDK Java 8 headless runtime environment
8 extra/jre9-openjdk 9.u181-4 [installed]
OpenJDK Java 9 full runtime environment
9 extra/jre9-openjdk-headless 9.u181-4 [installed]
OpenJDK Java 9 headless runtime environment
10 extra/openjdk7-doc 7.u151_2.6.11-1
OpenJDK Java 7 documentation
11 extra/openjdk7-src 7.u151_2.6.11-1
OpenJDK Java 7 sources
12 extra/openjdk8-doc 8.u144-1
OpenJDK Java 8 documentation
13 extra/openjdk8-src 8.u144-1
OpenJDK Java 8 sources
14 extra/openjdk9-doc 9.u181-4
OpenJDK Java 9 documentation
15 extra/openjdk9-src 9.u181-4
OpenJDK Java 9 sources
16 extra/visualvm 1.3.9-1
Visual tool integrating several commandline JDK tools and lightweight 
profiling capabilities
17 community/java-atk-wrapper-openjdk7 0.33.3-1
ATK wrapper for screen reader access to Java Swing applications - OpenJDK 7
18 community/java-atk-wrapper-openjdk8 0.33.3-1
ATK wrapper for screen reader access to Java Swing applications - OpenJDK 8
19 aur/bin32-jdk 8u152-1 (16) (0.33)
Oracle Java 8 Development Kit (32-bit)
20 aur/bin32-jdk5 5u22-1 (2) (0.00)
Oracle Java 5 Development Kit (32-bit) (public release - end of support)
21 aur/bin32-jdk6 6u45-5 (3) (0.00)
Oracle Java 6 Development Kit (32-bit) (public release - end of support)
22 aur/bin32-jdk7 7u80-1 (7) (0.00)
Oracle Java 7 Development Kit (32-bit) (public release - end of support)
23 aur/intellij-idea-ce 2017.3.1-1 (18) (2.20)
Intellij Idea IDE (community version) with Intellij JDK
24 aur/intellij-jdk 8u152b1056.12-1 (18) (1.02)
OpenJDK Java 8 development kit with some fixes and enhancements by 
JetBrains
25 aur/java8-openjdk-hsdis 8.u112-1 (1) (0.00)
Disassembler for HotSpot
26 aur/jdk 9.0.1-1 (769) (4.52)
Oracle Java Development Kit
27 aur/jdk-arm 8u152-1 (11) (0.00)
Oracle Java Development Kit (v8) for ARMv7, ARMv6 and ARMv8 (64-bit)
28 aur/jdk-dcevm 8u144-1 (1) (0.01)
Oracle Java Development Kit with DCEVM patches
29 aur/jdk-demos 8u152-1 (7) (0.00)
Demos and samples of common tasks and new functionality in Oracle Java 8 
Development Kit
30 aur/jdk-devel 10b35-1 (36) (0.29)
Oracle Java 10 Development Kit Snapshot
31 aur/jdk-devel-docs 10b35-1 (6) (0.20)
Documentation for Oracle Java 10 Development Kit Snapshot
32 aur/jdk-docs 9.0.1-1 (53) (0.66)
Documentation for Oracle Java Development Kit
33 aur/jdk5 5u22-1 (3) (0.00)
Oracle Java 5 Development Kit (public release - end of support)
34 aur/jdk6 6u45-6 (80) (1.01)
Oracle Java 6 Development Kit (public release - end of support)
35 aur/jdk6-docs 6u30-1 (3) (0.18)
Documentation for Oracle Java 6 Development Kit
36 aur/jdk7 7u80-1 (133) (0.14)
Oracle Java 7 Development Kit (public release - end of support)
37 aur/jdk7-docs 7.80-1 (13) (0.18)
Java SE Development Kit Documentation 7
38 aur/jdk7-j9-bin 7.0.10.15-1 (0) (0.00)
IBM�� SDK, Java Technology Edition, Version 7
39 aur/jdk7-openjdk-infinality 7.u151_2.6.11-1 (26) (0.00)
OpenJDK Java 7 development kit
40 aur/jdk7r1-j9-bin 7.1.4.15-1 (0) (0.00)
IBM�� SDK, Java Technology Edition, Version 7 Release 1
41 aur/jdk8 8u152-1 (26) (10.52)
Oracle Java 8 Development Kit
42 aur/jdk8-docs 8u152-1 (4) (1.74)
Documentation for Oracle Java 8 Development Kit
43 aur/jdk8-j9-bin 8.0.5.0-1 (Out of Date) (3) (0.20)
IBM�� SDK, Java Technology Edition, Version 8
44 aur/jdk8-openj9-bin 8u152-b16-1 (2) (1.35)
Eclipse (former IBM) OpenJ9 with openjdk8
45 aur/jdk8-openjdk-infinality 8.u152-1 (29) (0.19)
OpenJDK Java 8 development kit with infinality patch applied
46 aur/jdk8-openjdk-jetbrains 8.u152.b1024.10-1 (9) (0.06)
OpenJDK Java 8 development kit (with JetBrains patches)
47 aur/jdk9-openj9-bin 9.181-2 (5) (2.20)
Eclipse (former IBM) OpenJ9 with openjdk9
48 aur/jre7-openjdk-headless-infinality 7.u151_2.6.11-1 (26) (0.00)
OpenJDK Java 7 headless runtime environment
49 aur/jre7-openjdk-infinality 7.u151_2.6.11-1 (26) (0.00)
OpenJDK Java 7 full runtime environment
50 aur/jre8-openjdk-headless-infinality 8.u152-1 (29) (0.19)
OpenJDK Java 8 headless runtime environment with infinality patch applied
51 aur/jre8-openjdk-infinality 8.u152-1 (29) (0.19)
OpenJDK Java 8 full runtime environment with infinality patch applied
52 aur/jre8-openjdk-jetbrains 8.u152.b1024.10-1 (9) (0.06)
OpenJDK Java 8 full runtime environment (with JetBrains patches)
53 aur/jre8-openjdk-jetbrains-headless 8.u152.b1024.10-1 (9) (0.06)
OpenJDK Java 8 headless runtime environment (with JetBrains patches)
54 aur/ldapjdk 4.19-1 (2) (0.00)
The Mozilla LDAP Java SDK
55 aur/openjdk8-jetbrains-doc 8.u152.b1024.10-1 (9) (0.06)
OpenJDK Java 8 documentation (with JetBrains patches)
56 aur/openjdk8-jetbrains-src 8.u152.b1024.10-1 (9) (0.06)
OpenJDK Java 8 sources (with JetBrains patches)
57 aur/tuxjdk 8.152.03-1 (Out of Date) (5) (0.00)
Enhanced Open Java Development Kit for developers on Linux. Contains 
series of patched to OpenJDK to enhance user experience with Java-based 
and Swing-based tools (NetBeans, Idea, Android Studio, etc)
58 aur/tuxjdk-doc 8.152.03-1 (Out of Date) (5) (0.00)
OpenJDK Java 8 documentation
59 aur/tuxjdk-src 8.152.03-1 (Out of Date) (5) (0.00)
OpenJDK Java 8 sources
60 aur/zulu-jdk 8u144b01-1 (Out of Date) (2) (0.71)
Zulu JVM built upon OpenJDK 8
==> Enter n�� of packages to be installed (e.g., 1 2 3 or 1-3)
==> ----------------------------------------------------------
==>

As you see in the above output, these commands display the list of available JDK versions. Just type the number of your choice.

Here, I chose the number: 47.

During installation, you will be asked to enter the password for the administrative account. Enter the password and wait for few moments to complete the installation.

After the installation is over, check the java version using the command:

java -version

Sample Output:

[ashwin@archlinux ~]$ java -version
openjdk version "9"
OpenJDK Runtime Environment (build 9+181)
OpenJDK 64-Bit Server VM (build 9+181, mixed mode)

As you see in the above output, Oracle Java has been installed.

You can check where is Java using the command below:

whereis java

Sample Output:

[ashwin@archlinux ~]$ whereis java
java: /usr/bin/java /usr/lib/java /usr/share/java /usr/lib/jvm/java-9-openjdk/bin/java

That’s it. If you find this guide useful, please share it on your social, professional networks and support us. I will be here soon with another article soon. Until then, stay tuned to Facebook page Techfuzz. You can comment for any help or you can surf to arch web page. Click Here

Leave a Comment

Your email address will not be published. Required fields are marked *

Share via
Copy link