I am on UBUNTU. JDK version currently installed is:
java version \"1.7.0_51\"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Se
You can easily install 1.8 via PPA. Which can be done by:
$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update
$ sudo apt-get install oracle-java8-installer
Then check the running version:
$ java -version
If you must do it manually there's already an answer for that on AskUbuntu here.