From http://blog.csdn.net/skykingf/article/details/45267517
code:
sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install oracle-java8-installer