简体   繁体   中英

Spark install error on Ubuntu 14.04 missing javac?

I was installing Spark on my Ubuntu 14.04 and it seemed to be going smoothly for quite a while then bombed with I have previously installed and checked Scala... and see details of Java at bottom..

    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
[error] (streaming-flume-sink/compile:compile) java.io.IOException: Cannot run program "/usr/lib/jvm/java-7-openjdk-amd64/bin/javac": error=2,    No such file or directory
[error] (unsafe/compile:compile) java.io.IOException: Cannot run program "/usr/lib/jvm/java-7-openjdk-amd64/bin/javac": error=2, No such file or directory
[error] (network-common/compile:compile) java.io.IOException: Cannot run program "/usr/lib/jvm/java-7-openjdk-amd64/bin/javac": error=2, No such file or directory
[error] (launcher/compile:compile) java.io.IOException: Cannot run program "/usr/lib/jvm/java-7-openjdk-amd64/bin/javac": error=2, No such file or directory
[error] Total time: 737 s, completed Nov 9, 2015 4:37:48 PM

I have Java installed:

tom@tom-sam:~$ java -version
java version "1.7.0_85"
OpenJDK Runtime Environment (IcedTea 2.6.1) (7u85-2.6.1-5ubuntu0.14.04.1)
OpenJDK 64-Bit Server VM (build 24.85-b03, mixed mode)

Any ideas??

I have Java installed:

 tom@tom-sam:~$ java -version java version "1.7.0_85" OpenJDK Runtime Environment (IcedTea 2.6.1) (7u85-2.6.1-5ubuntu0.14.04.1) OpenJDK 64-Bit Server VM (build 24.85-b03, mixed mode) 

You have the java runtime installed (the JRE). You need the JDK (Java Developer Kit). You can install the Oracle JDK , or the OpenJDK . For the OpenJDK, it should be as simple as

$ sudo apt-get install default-jdk

For the Oracle JDK, it's only a little more involved,

$ sudo apt-get install python-software-properties
$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update

Then one of

$ sudo apt-get install oracle-java6-installer

or

$ sudo apt-get install oracle-java7-installer

or

$ sudo apt-get install oracle-java8-installer

For Java 6, 7 or 8 respectively.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM