猿问

想要打开spark-shell的时候打不开了,提示如下:该怎么解决?

打算用spark连接hbase读取数据,不知道是不是复制了有问题的jar,还是之前输入的语句有问题,还是因为别的原因,打开spark-shell的时候已经打不开了,提示如下
Setting default log level to "WARN".
To adjust logging level use sc.setLogLevel(newLevel).
Exception in thread "main" java.lang.IllegalAccessError: tried to access field org.slf4j.impl.StaticLoggerBinder.SINGLETON from class org.slf4j.LoggerFactory
at org.slf4j.LoggerFactory.<clinit>(LoggerFactory.java:60)
at org.apache.spark.internal.Logging$class.log(Logging.scala:47)
at org.apache.spark.repl.Main$.log(Main.scala:30)
at org.apache.spark.internal.Logging$class.initializeLogging(Logging.scala:148)
at org.apache.spark.internal.Logging$class.initializeLogIfNecessary(Logging.scala:102)
at org.apache.spark.repl.Main$.initializeLogIfNecessary(Main.scala:30)
at org.apache.spark.repl.Main$.<init>(Main.scala:32)
at org.apache.spark.repl.Main$.<clinit>(Main.scala)
at org.apache.spark.repl.Main.main(Main.scala)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:736)
at org.apache.spark.deploy.SparkSubmit$.doRunMain$1(SparkSubmit.scala:185)
at org.apache.spark.deploy.SparkSubmit$.submit(SparkSubmit.scala:210)
at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:124)
at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)
谢谢了

慕后森
浏览 325回答 1
1回答

阿晨1998

试试在spark-env.sh中设置: export SPARK_MASTER_IP=127.0.0.1 export SPARK_LOCAL_IP=127.0.0.1
随时随地看视频慕课网APP
我要回答