Hi Akka Team,

To prepare a deployment using docker, I try to start in my laptop a cluster 
with 3 nodes : 2 nodes workers (seed-nodes) and 1 node as cluster client. 

When I start the first seed node and then second one, this last is not 
joining the cluster as expected. I follow the instructions from akka 
cluster with docker 
<http://www.lightbend.com/activator/template/akka-docker-cluster>.

In the tutorial, the file application.conf do not contains seed-nodes 
because it should be added when the different file configurations have been 
resolved but in my case, I didn't have this impression. 

I have the following three files configuration (application.conf, 
node.seed.conf, node.cluster) : 

// application.conf

akka {
  remote {
    netty.tcp {
      hostname = ${clustering.ip}
      port = ${clustering.port}
    }
  }
}


clustering {
  port = ${?CLUSTER_PORT}
  ip = ${?CLUSTER_IP}
  cluster.name = "APP"
}

// node.seed.conf 
akka.cluster {
  seed-nodes += "akka.tcp://"${clustering.cluster.name}"@"${clustering.ip}
":"${clustering.port}
  roles = [workers]
}


// node.cluster.conf
akka.cluster {
  seed-nodes += "akka.tcp://"${clustering.cluster.name}"@"${clustering.ip}
":"${clustering.port}
  roles = [workers]
}


Then I have my Akka application code for running the code of seed-nodes : 


object WorkersApp extends LazyLogging {


  def main(args: Array[String]): Unit = {


    val CLUSTER_NAME_PATH = "clustering.cluster.name"


    val WORKER_NODE_CONF = "node.seed.conf"


    lazy val akkaConfig = ConfigFactory.load("application.conf")


    lazy val actorSystemName = akkaConfig getString CLUSTER_NAME_PATH


    val actorSystemConfig =
      (ConfigFactory parseResources WORKER_NODE_CONF)
        .withFallback(akkaConfig)
        .resolve()


    implicit val system =
      ActorSystem(actorSystemName, actorSystemConfig)


    // Create some actor
}

When I'm creating the first seed node using CLUSTER_IP=localhost and 
CLUSTER_PORT=2551, I have following logs : 

[info] [INFO] [05/05/2017 15:30:51.018] [main] [akka.remote.Remoting] 
Starting remoting
[info] [INFO] [05/05/2017 15:30:51.127] [main] [akka.remote.Remoting] 
Remoting started; listening on addresses :[akka.tcp://[email protected]:2551]
[info] [INFO] [05/05/2017 15:30:51.127] [main] [akka.remote.Remoting] 
Remoting now listens on addresses: [akka.tcp://[email protected]:2551]
[info] [INFO] [05/05/2017 15:30:51.135] [main] 
[akka.cluster.Cluster(akka://FGS)] 
Cluster Node [akka.tcp://[email protected]:2551] - Starting up...
[info] [INFO] [05/05/2017 15:30:51.193] [main] 
[akka.cluster.Cluster(akka://FGS)] 
Cluster Node [akka.tcp://[email protected]:2551] - Registered cluster JMX MBean 
[akka:type=Cluster]
[info] [INFO] [05/05/2017 15:30:51.193] [main] 
[akka.cluster.Cluster(akka://FGS)] 
Cluster Node [akka.tcp://[email protected]:2551] - Started up successfully
[info] [INFO] [05/05/2017 15:30:51.213] [FGS-akka.actor.default-dispatcher-4
] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2551] - Node [akka.tcp://[email protected]:2551] is 
JOINING, roles [workers]
[info] [INFO] [05/05/2017 15:30:51.223] [FGS-akka.actor.default-dispatcher-4
] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2551] - Leader is moving node 
[akka.tcp://[email protected]:2551] to [Up]
[info] [INFO] [05/05/2017 15:30:51.254] [FGS-akka.actor.default-dispatcher-
15] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2551] - Metrics will be retreived from MBeans, 
and may be incorrect on some platforms. To increase metric accuracy add the 
'sigar.jar' to the classpath and the appropriate platform-specific native 
libary to 'java.library.path'. Reason: java.lang.IllegalArgumentException: 
java.lang.UnsatisfiedLinkError: org.hyperic.sigar.Sigar.getPid()J
[info] [INFO] [05/05/2017 15:30:51.255] [FGS-akka.actor.default-dispatcher-
15] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2551] - Metrics collection has started 
successfully



and then for the second seed node using CLUSTER_IP=localhsot and 
CLUSTER_PORT=2552, I have following logs : 

[info] [INFO] [05/05/2017 15:31:48.692] [main] [akka.remote.Remoting] 
Starting remoting
[info] [INFO] [05/05/2017 15:31:48.803] [main] [akka.remote.Remoting] 
Remoting started; listening on addresses :[akka.tcp://[email protected]:2552]
[info] [INFO] [05/05/2017 15:31:48.804] [main] [akka.remote.Remoting] 
Remoting now listens on addresses: [akka.tcp://[email protected]:2552]
[info] [INFO] [05/05/2017 15:31:48.811] [main] 
[akka.cluster.Cluster(akka://FGS)] 
Cluster Node [akka.tcp://[email protected]:2552] - Starting up...
[info] [INFO] [05/05/2017 15:31:48.862] [main] 
[akka.cluster.Cluster(akka://FGS)] 
Cluster Node [akka.tcp://[email protected]:2552] - Registered cluster JMX MBean 
[akka:type=Cluster]
[info] [INFO] [05/05/2017 15:31:48.862] [main] 
[akka.cluster.Cluster(akka://FGS)] 
Cluster Node [akka.tcp://[email protected]:2552] - Started up successfully
[info] [INFO] [05/05/2017 15:31:48.883] [FGS-akka.actor.default-dispatcher-2
] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2552] - Node [akka.tcp://[email protected]:2552] is 
JOINING, roles [workers]
[info] [INFO] [05/05/2017 15:31:48.895] [FGS-akka.actor.default-dispatcher-2
] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2552] - Leader is moving node 
[akka.tcp://[email protected]:2552] to [Up]
[info] [INFO] [05/05/2017 15:31:48.924] [FGS-akka.actor.default-dispatcher-
15] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2552] - Metrics will be retreived from MBeans, 
and may be incorrect on some platforms. To increase metric accuracy add the 
'sigar.jar' to the classpath and the appropriate platform-specific native 
libary to 'java.library.path'. Reason: java.lang.IllegalArgumentException: 
java.lang.UnsatisfiedLinkError: org.hyperic.sigar.Sigar.getPid()J
[info] [INFO] [05/05/2017 15:31:48.925] [FGS-akka.actor.default-dispatcher-
15] [akka.cluster.Cluster(akka://FGS)] Cluster Node 
[akka.tcp://[email protected]:2552] - Metrics collection has started 
successfully


My two seed nodes looks like completely disconnected, the second seed node 
should contact the first seed node but it's not case. 

Any advice to solve this issue ? Thanks !

My two seed nodes looks like completely disconnected Modifier



-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to