Getting Java to work with Windows 10 Ubuntu

I installed the Windows 10 Anniversary Update to try Bash on Ubuntu on Windows. See how to install it . I wanted to see how it was. Then I installed the Oracle JDK according to this article , so I could compare the compilation time with my own Windows Java compiler.

Then I tried to run Maven in my project, but that didn't work. Maven just hung up. I noticed in the task manager that the "java" process hung around 92% of the CPU.

So, I tried something simple. I created the Java mannequin Hello-world-like class and tried to compile it using javac. Similarly, the javac process consisted of 92% of the CPU.

I thought this might be due to running headless, but the option -Djava.awt.headless=true not improved.

Has anyone got this to work or try something?

Update:

I also tried installing Open JDK instead of Oracle JDK (via sudo apt-get install openjdk-7-jdk ) with the same result.

+5
source share
2 answers

I get it. I could not use loading directly from Oracle. Instead, I had to install it from this link . Here are the steps:

 sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install oracle-java7-installer 
+3
source

I had the same experience with the Windows 10 Anniversary Update. The first insider build of Fast Track after the Anniversary Update and the subsequent support for both the Oracle 8 installer and the JDK 7 open installer. I just checked that the java -version team still works in Insider Preview Build 14951 161014-1700 from the Ubuntu bash subsystem . I also ran other JVM-based tools from the bash shell, but not widely.

Here is a link to the problem, Unable to install Oracle JDK 8 # 315 , describing installation issues and JVM hangs tracked by BashOnWindows .

+1
source

Source: https://habr.com/ru/post/1258543/


All Articles