Akka cluster couldn't join seed nodes

akka-cluster

(Rhell21) #1

Hi , Im trying to cluster two different hosts but getting below error. I had deployed a sample code(implementing akka cluster) in 3 hosts (127.0.0.1, host1 and host2), and when i try to connect them by configuring them in seed-nodes, as given below

netty.tcp {
hostname = “127.0.0.1”
port = 2551
}

“akka.tcp://AkkaTaskProcessing@127.0.0.1:2551”,“akka.tcp://AkkaTaskProcessing@host2:2551”,“akka.tcp://AkkaTaskProcessing@host1:2551”

Even tried using different port number but same error.

Error log:
[INFO] [01/07/2019 16:23:11.331] [main] [akka.remote.Remoting] Starting remoting
[INFO] [01/07/2019 16:23:11.798] [main] [akka.remote.Remoting] Remoting started; listening on addresses :[akka.tcp://AkkaTaskProcessing@127.0.0.1:2551]
[INFO] [01/07/2019 16:23:11.801] [main] [akka.remote.Remoting] Remoting now listens on addresses: [akka.tcp://AkkaTaskProcessing@127.0.0.1:2551]
[INFO] [01/07/2019 16:23:11.854] [main] [akka.cluster.Cluster(akka://AkkaTaskProcessing)] Cluster Node [akka.tcp://AkkaTaskProcessing@127.0.0.1:2551] - Starting up, Akka version [2.5.13] …
[INFO] [01/07/2019 16:23:12.027] [main] [akka.cluster.Cluster(akka://AkkaTaskProcessing)] Cluster Node [akka.tcp://AkkaTaskProcessing@127.0.0.1:2551] - Registered cluster JMX MBean [akka:type=Cluster,port=2551]
[INFO] [01/07/2019 16:23:12.027] [main] [akka.cluster.Cluster(akka://AkkaTaskProcessing)] Cluster Node [akka.tcp://AkkaTaskProcessing@127.0.0.1:2551] - Started up successfully
[WARN] [01/07/2019 16:23:13.661] [AkkaTaskProcessing-akka.remote.default-remote-dispatcher-6] [akka.tcp://AkkaTaskProcessing@127.0.0.1:2551/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FAkkaTaskProcessing%40host1%3A2551-1] Association with remote system [akka.tcp://AkkaTaskProcessing@host1:2551] has failed, address is now gated for [500] ms. Reason: [Association failed with [akka.tcp://AkkaTaskProcessing@host1:2551]] Caused by: [java.net.ConnectException: Connection refused: no further information: /host1:2551]
[WARN] [01/07/2019 16:23:13.661] [New I/O boss #3] [NettyTransport(akka://AkkaTaskProcessing)] Remote connection to [null] failed with java.net.ConnectException: Connection refused: no further information: /host1:2551
[WARN] [01/07/2019 16:23:13.676] [New I/O boss #3] [NettyTransport(akka://AkkaTaskProcessing)] Remote connection to [null] failed with java.net.ConnectException: Connection refused: no further information: /host2:2551


(Tim Moore) #2

These errors say that the process running on 127.0.0.1 couldn’t connect to host1 and host2. How are you running the other two hosts? Are you sure there isn’t a firewall configuration interfering?