Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error: Invalid or corrupt jarfile sbt/sbt-launch-0.13.5.jar

I have been trying to install spark using the tutorial and everytime I run the command sbt/sbt assembly, I get the error "Error: Invalid or corrupt jarfile sbt/sbt-launch-0.13.5.jar"

I have tried everything: seperately adding the sbt file to the sbt folder in the spark folder, installing sbt individually, checking the download and reinstalling it over again, but in vain. Any advice about what I am doing wrong? Thanks.

like image 390
user2330778 Avatar asked Jul 23 '15 18:07

user2330778


1 Answers

If you have downloaded spark package from http://d3kbcqa49mib13.cloudfront.net/spark-1.1.0.tgz then cross check file - "sbt/sbt-launch-0.13.5.jar". If it just contains small (5-6lines) html content then you need to download jar file manually. This html file just indicate that required jar file was not found. You may use follow following steps for centos:

  1. Download jar manually:
    wget http://dl.bintray.com/typesafe/ivy-releases/org.scala-sbt/sbt-launch/0.13.1/sbt-launch.jar ./sbt/sbt-launch-0.13.5.jar
  2. Prevent automatic downloading of jar file:
    sed -i '47,68s/^/#/' sbt/sbt-launch-lib.bash
  3. Install spark again:
    sbt/sbt assembly

It worked for me without altering scala installation. Hope it helps.

like image 109
Jyoti Gupta Avatar answered Sep 28 '22 00:09

Jyoti Gupta