打的jar运行时报错

来源:5-2 -A SQLContext的使用

慕圣8049820

2018-09-08

我在windows上打的jar,放在linux上运行时报错;
Exception in thread “main” java.lang.SecurityException: Invalid signature file digest for Manifest main attributes
at sun.security.util.SignatureFileVerifier.processImpl(SignatureFileVerifier.java:240)
at sun.security.util.SignatureFileVerifier.process(SignatureFileVerifier.java:193)
at java.util.jar.JarVerifier.processEntry(JarVerifier.java:307)
at java.util.jar.JarVerifier.update(JarVerifier.java:218)
at java.util.jar.JarFile.initializeVerifier(JarFile.java:345)

org.apache.spark.deploy.SparkSubmit.org.org.orgapachesparksparksparkdeploySparkSubmitSparkSubmitSparkSubmitrunMain(SparkSubmit.scala:695)atorg.apache.spark.deploy.SparkSubmitrunMain(SparkSubmit.scala:695) at org.apache.spark.deploy.SparkSubmitrunMain(SparkSubmit.scala:695)atorg.apache.spark.deploy.SparkSubmit.doRunMain1(SparkSubmit.scala:187)atorg.apache.spark.deploy.SparkSubmit1(SparkSubmit.scala:187) at org.apache.spark.deploy.SparkSubmit1(SparkSubmit.scala:187)atorg.apache.spark.deploy.SparkSubmit.submit(SparkSubmit.scala:212)
at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:126)
at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)

在服务器上运行的命令为:
spark-submit \

–class com.imooc.spark.SQLContextApp
–master local[2]
/home/hadoop/lib/ImoocSparkSQLProject.jar
file:///home/hadoop/app/spark-2.1.0-bin-2.6.0-cdh5.7.0/examples/src/main/resources/people.json
麻烦老师看下怎么解决?

写回答

2回答

Michael_PK

2018-09-08

再次: 提交脚本—name?

0
1
Michael_PK
我写错了,是—master?
2018-09-08
共1条回复

Michael_PK

2018-09-08

首先:你是maven打包吗? 其次:你的submit脚本换行了没有\?

0
2
Michael_PK
回复
慕圣8049820
用mvn命令打包
2018-09-08
共2条回复

以慕课网日志分析为例 进入大数据Spark SQL的世界

快速转型大数据:Hadoop,Hive,SparkSQL步步为赢

1644 学习 · 1129 问题

查看课程