Installing and configuring Java JDK and Netbeans 8.1 in Linix Ubuntu 16.04 (LTS)

Installing and configuring Java JDK and Netbeans 8.1 in Linix Ubuntu 16.04 (LTS)
Tutorial Title: Installing and configuring JDK  (Java Development Kit) and Netbeans 8.1 in Linix Ubuntu 16.04 (LTS)

Course: Programming

Instructor: Muhammad Samim
Note: Copy and paste commands in terminal after dollar sign ($)


Part 1. Installing JDK (Java Development Kit)
  1. Download jdk-8u101-linux-x64.tar.gz (64 bit or 32 bit depends on your installed OS) from bellow link
  2. http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
  3. Open terminal or press Ctrl + Alt + t to open terminal
  4.  command for home folder $ cd ~
  5. opening Downloads folder where is downloaded file $ cd Downloads/
  6. Show files and folders $ ls
  7. Extracting zip file $ tar -zxvf jdk-8u101-linux-x64.tar.gz
  8. After extraction folder will be appeared (jdk1.8.0_101)
  9. Creating folder $ sudo mkdir /usr/lib/ java
  10. Should be in Downloads folder where file is extracted $ cd ~
  11. $ cd Downloads/
  12. Moving folder to created java folder $ mv jdk1.8.0_101 /usr/lib/java
  13. Now open .bashrc file to save path of Java
  14. $ cd ~
  15. $ sudo gedit .bashrc
  16. Copy and paste bellow two lines at the end and save file
  17. export JAVA_HOME=/usr/lib/java/jdk1.8.0_101
    export PATH="$PATH:$JAVA_HOME/bin"
 Part 2: Installing Netbeans 8.1

  1. Download netbeans-8.1-linux.sh file from bellow line 
  2. http://netbeans.org/downloads/start.html?platform=linux&lang=en&option=all
  3. Come to home dir $ cd ~
  4. Open Downloads where netbeans-8.1-linux.sh is downloaded $ cd Downloads/
  5. $ sudo chmod 777 netbeans-8.1-linux.sh
  6. Installation Wizard will be appeared
  7. Follow the instruction 
  8. After installation Netbeans IDE will be able to execute your java programs