Has anyone tried Alvin Alexanders remote example on an ipv6 only (not mixed
ipv4/v6) machine say with akka 2.3.12 and scala 2.11.6 with java 7.
When i try this running both the local (client) and the remote (server
actor) i get this crazy at the local client and no success messages.
# scala -Dhost=2001:1b70:82a7:1099:10:61:140:130
-Dconfig.file=/home/bord/my.conf -cp .:/opt/ngee/latest/base/lib/3pp/*
local.Local 17:54:34.353
[LocalSystem-akka.actor.default-dispatcher-9] INFO
akka.event.slf4j.Slf4jLogger - Slf4jLogger started
17:54:34.425 [LocalSystem-akka.actor.default-dispatcher-6] INFO Remoting -
Starting remoting
17:54:34.702 [LocalSystem-akka.actor.default-dispatcher-4] INFO Remoting -
Remoting started; listening on addresses
:[akka.tcp://LocalSystem@2001:1b70:82a7:1099:10:61:140:130:51111]
17:54:34.708 [LocalSystem-akka.actor.default-dispatcher-3] INFO Remoting -
Remoting now listens on addresses:
[akka.tcp://LocalSystem@2001:1b70:82a7:1099:10:61:140:130:51111]
17:54:34.725 [LocalSystem-akka.actor.default-dispatcher-3] INFO
a.r.RemoteActorRefProvider$RemoteDeadLetterActorRef - Message
[java.lang.String] from
Actor[akka://LocalSystem/user/LocalActor#2029483167] to
Actor[akka://LocalSystem/deadLetters] was not delivered. [1] dead letters
encountered. This logging can be turned off or adjusted with configuration
settings 'akka.log-dead-letters' and
'akka.log-dead-letters-during-shutdown'.
Meanwhile the server (remote side) seems to run fine although with a
similar message about deadletters delivery failed ---
# scala -Dconfig.file=remote/application.conf -cp
.:/opt/ngee/latest/base/lib/3pp/* remote.HelloRemote
[DEBUG] [08/19/2015 03:55:31.754] [main]
[EventStream(akka://HelloRemoteSystem)] logger log1-Logging$DefaultLogger
started
[DEBUG] [08/19/2015 03:55:31.755] [main]
[EventStream(akka://HelloRemoteSystem)] Default Loggers started
[INFO] [08/19/2015 03:55:31.833] [main] [Remoting] Starting remoting
[INFO] [08/19/2015 03:55:32.145] [main] [Remoting] Remoting started;
listening on addresses
:[akka.tcp://HelloRemoteSystem@2001:1b70:82a7:1099:10:61:140:130:5150]
[INFO] [08/19/2015 03:55:32.148] [main] [Remoting] Remoting now listens on
addresses:
[akka.tcp://HelloRemoteSystem@2001:1b70:82a7:1099:10:61:140:130:5150]
RemoteActor received message 'The RemoteActor is alive'
[INFO] [08/19/2015 03:55:32.161]
[HelloRemoteSystem-akka.actor.default-dispatcher-4]
[akka://HelloRemoteSystem/deadLetters] Message [java.lang.String] from
Actor[akka://HelloRemoteSystem/user/RemoteActor#-46932872] to
Actor[akka://HelloRemoteSystem/deadLetters] was not delivered. [1] dead
letters encountered. This logging can be turned off or adjusted with
configuration settings 'akka.log-dead-letters' and
'akka.log-dead-letters-during-shutdown'.
I have no issues with the remote example on a very similar but ipv4 setup.
The client side akka configuration has hard-coded correct ipv6 address
(matches the /etc/hosts on the machine and exactly what scala repl says is
the getHostAddress())
# akka 2.1
akka {
loglevel = "DEBUG"
actor {
provider = "akka.remote.RemoteActorRefProvider"
}
remote {
transport = "akka.remote.netty.NettyRemoteTransport"
//log-sent-messages = on
//log-received-messages = on
netty {
tcp {
hostname = "2001:1b70:82a7:1099:10:61:140:130"
port = 0
}
}
}
}
----
# scala
Welcome to Scala version 2.11.6 (Java HotSpot(TM) 64-Bit Server VM, Java
1.7.0_85).
Type in expressions to have them evaluated.
Type :help for more information.
scala> java.net.InetAddress.getLocalHost.getHostAddress()
res0: String = 2001:1b70:82a7:1099:10:61:140:130
-----
for completeness the server side akka config
akka {
loglevel = "DEBUG"
actor {
provider = "akka.remote.RemoteActorRefProvider"
}
remote {
transport = "akka.remote.netty.NettyRemoteTransport"
//log-sent-messages = on
//log-received-messages = on
netty {
tcp {
hostname = "2001:1b70:82a7:1099:10:61:140:130"
port = 5150
}
}
}
}
----
Elsewhere on the web there are rumors that akka and ipv6 may work according
to some mailings.
But i've not been able to get it to work nor find any substantiated
information.
Also any information on the 2.4 version of akka with ipv6 is appreciated.
cheers
Craig
On Monday, October 13, 2014 at 5:51:49 AM UTC-4, sifi mohamed amine wrote:
>
>
>
> Hello ,
>
> Trying to to lauch the example in this tutorial :
> http://alvinalexander.com/scala/scala-akka-actors-ping-pong-simple-example
> and more importantly configuring it work for Ipv6 , I got this exception .
>
> [error] (run-main-0)
> 451d3fcc-931e-4802-9c77-5b13f45cf3f5akka.remote.RemoteTransportException:
> Could not load remote transport layer akka.remote.netty.NettyRemoteTransport
> 451d3fcc-931e-4802-9c77-5b13f45cf3f5akka.remote.RemoteTransportException:
> Could not load remote transport layer akka.remote.netty.NettyRemoteTransport
> at
> akka.remote.RemoteActorRefProvider$$anonfun$init$2.applyOrElse(RemoteActorRefProvider.scala:87)
> at
> akka.remote.RemoteActorRefProvider$$anonfun$init$2.applyOrElse(RemoteActorRefProvider.scala:86)
> at
> scala.runtime.AbstractPartialFunction.apply(AbstractPartialFunction.scala:33)
> at scala.util.Failure$$anonfun$recover$1.apply(Try.scala:185)
> at scala.util.Try$.apply(Try.scala:161)
> at scala.util.Failure.recover(Try.scala:185)
> at
> akka.remote.RemoteActorRefProvider.init(RemoteActorRefProvider.scala:86)
> at akka.actor.ActorSystemImpl._start$lzycompute(ActorSystem.scala:583)
> at akka.actor.ActorSystemImpl._start(ActorSystem.scala:581)
> at akka.actor.ActorSystemImpl.start(ActorSystem.scala:590)
> at akka.actor.ActorSystem$.apply(ActorSystem.scala:110)
> at akka.actor.ActorSystem$.apply(ActorSystem.scala:92)
> at local.Local$delayedInit$body.apply(Local.scala:7)
> at scala.Function0$class.apply$mcV$sp(Function0.scala:40)
> at
> scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12)
> at scala.App$$anonfun$main$1.apply(App.scala:71)
> at scala.App$$anonfun$main$1.apply(App.scala:71)
> at scala.collection.immutable.List.foreach(List.scala:318)
> at
> scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:32)
> at scala.App$class.main(App.scala:71)
> at local.Local$.main(Local.scala:5)
> at local.Local.main(Local.scala)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> Caused by: java.net.UnknownHostException: fe80::e54:a5ff:fe00:7db2: Name
> or service not known
> at java.net.Inet6AddressImpl.lookupAllHostAddr(Native Method)
> at java.net.InetAddress$1.lookupAllHostAddr(InetAddress.java:901)
> at
> java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1293)
> at java.net.InetAddress.getAllByName0(InetAddress.java:1246)
> at java.net.InetAddress.getAllByName(InetAddress.java:1162)
> at java.net.InetAddress.getAllByName(InetAddress.java:1098)
> at java.net.InetAddress.getByName(InetAddress.java:1048)
> at akka.remote.netty.NettyRemoteServer.<init>(Server.scala:26)
> at
> akka.remote.netty.NettyRemoteTransport.createServer(NettyRemoteSupport.scala:156)
> at
> akka.remote.netty.NettyRemoteTransport.liftedTree1$1(NettyRemoteSupport.scala:149)
> at
> akka.remote.netty.NettyRemoteTransport.<init>(NettyRemoteSupport.scala:149)
> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
> Method)
> at
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
> at
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
> at
> akka.actor.ReflectiveDynamicAccess$$anonfun$createInstanceFor$2.apply(DynamicAccess.scala:79)
> at scala.util.Try$.apply(Try.scala:161)
> at
> akka.actor.ReflectiveDynamicAccess.createInstanceFor(DynamicAccess.scala:74)
> at
> akka.actor.ReflectiveDynamicAccess$$anonfun$createInstanceFor$3.apply(DynamicAccess.scala:85)
> at
> akka.actor.ReflectiveDynamicAccess$$anonfun$createInstanceFor$3.apply(DynamicAccess.scala:85)
> at scala.util.Success.flatMap(Try.scala:200)
> at
> akka.actor.ReflectiveDynamicAccess.createInstanceFor(DynamicAccess.scala:85)
> at
> akka.remote.RemoteActorRefProvider.init(RemoteActorRefProvider.scala:86)
> at akka.actor.ActorSystemImpl._start$lzycompute(ActorSystem.scala:583)
> at akka.actor.ActorSystemImpl._start(ActorSystem.scala:581)
> at akka.actor.ActorSystemImpl.start(ActorSystem.scala:590)
> at akka.actor.ActorSystem$.apply(ActorSystem.scala:110)
> at akka.actor.ActorSystem$.apply(ActorSystem.scala:92)
> at local.Local$delayedInit$body.apply(Local.scala:7)
> at scala.Function0$class.apply$mcV$sp(Function0.scala:40)
> at
> scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12)
> at scala.App$$anonfun$main$1.apply(App.scala:71)
> at scala.App$$anonfun$main$1.apply(App.scala:71)
> at scala.collection.immutable.List.foreach(List.scala:318)
> at
> scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:32)
> at scala.App$class.main(App.scala:71)
> at local.Local$.main(Local.scala:5)
> at local.Local.main(Local.scala)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> [trace] Stack trace suppressed: run last compile:run for the full output.
> ^[[A^[[A^[[A^[[A^Cmedamine@uranus:~/Akka/Akka-Remote/HelloLocal$ sbt
> [info] Loading project definition from
> /home/medamine/Akka/Akka-Remote/HelloLocal/project
> [info] Set current project to HelloLocal (in build
> file:/home/medamine/Akka/Akka-Remote/HelloLocal/)
>
> I should also mention that I am binding to my local IPv6 adress
> Can any suggest a solution .Thanks a lot
>
--
>>>>>>>>>> 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 http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.