Mobile sister, your installation method can be tested before sharing out, this is a very irresponsible sharing attitude!
Here's what I did 2 hours later:
1 ) will jdk-8u45-linux-i586.tar.gz copied to /opt/sinoknots/ below the directory, if the folder is not available, create the folder with the following command:
// Create Sinoknots folder
sudo mkdir/opt/sinoknots
// copied to Sinoknots folder
sudo cp-r jdk-8u45-linux-i586.tar.gz/opt/sinoknots
2 ) will jdk-8u45-linux-i586.tar.gz Unzip:
// extract to current directory
sudo tar-zxvf jdk-8u45-linux-i586.tar.gz
"This step will give you a table of contents: jdk1.8.0_45 "
3 ) to set the environment variables, using the gedit Open /etc/profile file
// Open File
sudo gedit/etc/profile
// At the end of the file, add the following text
Export java_home=/opt/sinoknots/jdk1.8.0_45
Export jre_home=/opt/sinoknots/jdk1.8.0_45/jre
Exportpath= $JAVA _home/bin: $JAVA _home/jre/bin: $PATH
Exportclasspath= $CLASSPATH:.: $JAVA _home/lib: $JAVA _home/jre/lib
4 ) to set the system default JDK change it. [ This step is important, if not modified, will cause the configured environment variable to not take effect ]
sudo update-alternatives--install/usr/bin/java java/opt/sinoknots/jdk1.8.0_45/bin/java 300
sudo update-alternatives--install/usr/bin/javac javac/opt/sinoknots/jdk1.8.0_45/bin/javac 300
This step you will choose the JDK environment in effect, of course, choose your own installed
sudo update-alternatives--config java
sudo update-alternatives--config javac
5 ) detection, input java-version
Java Version "1.8.0_45"
Java (TM) SE Runtime Environment (build 1.8.0_45-b14)
Java HotSpot (TM) Server VM (build 25.45-b02, Mixed mode)
Ubuntu Kylin Installation jdk-8u45-linux-i586.tar.gz