2017-09-26 2 views
1

Je suis en train de déployer une application Spark en utilisant le gestionnaire de cluster autonome sur les fenêtres, donc du côté maître (IP:. 192. 0,186) Je couru:travailleur: Impossible de se connecter à maîtriser sur étincelle apache

\bin>spark-class org.apache.spark.deploy.master.Master

et dans le côté esclave (IP:. 192. .75) Je couru:

\bin>spark-class org.apache.spark.deploy.worker.Worker spark://192.*.*.186:7077

J'ai un problème, e Le client ne peut pas se connecter au nœud maître et c'est l'erreur que j'obtiens:

17/09/26 12:00:51 WARN Worker: Failed to connect to master 192.*.*.186:7077 
org.apache.spark.SparkException: Exception thrown in awaitResult: 
    at org.apache.spark.util.ThreadUtils$.awaitResult(ThreadUtils.scala:205) 
    at org.apache.spark.rpc.RpcTimeout.awaitResult(RpcTimeout.scala:75) 
    at org.apache.spark.rpc.RpcEnv.setupEndpointRefByURI(RpcEnv.scala:100) 
    at org.apache.spark.rpc.RpcEnv.setupEndpointRef(RpcEnv.scala:108) 
    at org.apache.spark.deploy.worker.Worker$$anonfun$org$apache$spark$deploy$worker$Worker$$tryRegisterAllMasters$1$$anon$1.run(Worker.scala:241) 
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) 
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) 
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) 
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) 
    at java.lang.Thread.run(Thread.java:745) 
Caused by: java.io.IOException: Failed to connect to /192.*.*.186:7077 
    at org.apache.spark.network.client.TransportClientFactory.createClient(TransportClientFactory.java:232) 
    at org.apache.spark.network.client.TransportClientFactory.createClient(TransportClientFactory.java:182) 
    at org.apache.spark.rpc.netty.NettyRpcEnv.createClient(NettyRpcEnv.scala:197) 
    at org.apache.spark.rpc.netty.Outbox$$anon$1.call(Outbox.scala:194) 
    at org.apache.spark.rpc.netty.Outbox$$anon$1.call(Outbox.scala:190) 
    ... 4 more 
Caused by: io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: no further information: /192.*.*.186:7077 
    at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) 
    at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717) 
    at io.netty.channel.socket.nio.NioSocketChannel.doFinishConnect(NioSocketChannel.java:257) 
    at io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.finishConnect(AbstractNioChannel.java:291) 
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:631) 
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:566) 
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:480) 
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:442) 
    at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:131) 
    at io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:144) 
    ... 1 more 

Comment puis-je résoudre ce problème?

+0

pour tester la connexion entre les deux machines? –

Répondre

0
bin>spark-class org.apache.spark.deploy.worker.Worker spark://192.*.*.186:7077 

L'adresse IP principale mentionnée dans la commande ci-dessus est-elle correcte?

Vous avez écrit que l'adresse IP maître est 192 ... 168 mais dans la commande de démarrage esclave vous essayez avec 192. .. , typo: 6 et 8 inversés

+0

Bon, alors pouvez-vous essayer de faire telnet de la boîte esclave au maître en utilisant la commande suivante. > maître-ip telnet 7077 –

+0

De plus, ajoutez la ligne suivante dans le fichier: SPARK_HOME/conf/spark-env.sh 'SPARK_MASTER_IP = 192 ... 186' puis redémarrez le maître d'allumage –

+0

dans le travailleur ou dans le maître ? –