Installing Java on deepin is a mess. It's hard to figure it out and record it.
1. Download JDK
First of all, we need to know that the JDK downloaded using commands similar to sudo is an open JDK and an open source JDK. However, the JDK we use in school is from Oracle. So we need to go to the official website. You can skip the steps and use the command line to download them. After all, the open JDK and JDK are different. The former can be regarded as the castrated version of the latter,
Specific differences self Baidu: https://www.cnblogs.com/sxdcgaq8080/p/7487369.html
For specific steps, see section 78956497. Some people write quite well, that is, the configuration file path below may have less Java directories, so I won't duplicate them.
2. Configuration File
You may follow the above tutorial to clear the customs directly, but I am not so lucky. Execute source/etc/profile and keep saying that the path is a directory. I don't know why, the Java command cannot be found after the Java-version is added. After searching for a long time, I did not find any problem. I simply gave up the configuration method.
Https://bbs.deepin.org/forum.php? MoD = viewthread & tid = 136610. I configured it in this way, but it succeeded. The difference is that you changed the profile file and I changed the environment file. Of course, if you can use profile, you can change the profile first.
3. tomcat installation
There is nothing to say about this. For details, refer to 79632924. Good luck!
Install JDK and tomcat in deepin