sbt.ForkMain$ForkError: Address already in use

github.com | 5 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.

Root Cause Analysis

  1. sbt.ForkMain$ForkError

    Address already in use

    at sun.nio.ch.Net.bind0()
  2. Java RT
    ServerSocketAdaptor.bind
    1. sun.nio.ch.Net.bind0(Native Method)
    2. sun.nio.ch.Net.bind(Net.java:444)
    3. sun.nio.ch.Net.bind(Net.java:436)
    4. sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:214)
    5. sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
    6. sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:67)
    6 frames
  3. Zookeeper
    NIOServerCnxnFactory.configure
    1. org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:95)
    1 frame
  4. Spark Project External Kafka
    JavaKafkaStreamSuite.setUp
    1. org.apache.spark.streaming.kafka.KafkaTestUtils$EmbeddedZookeeper.<init>(KafkaStreamSuite.scala:200)
    2. org.apache.spark.streaming.kafka.KafkaStreamSuite.beforeFunction(KafkaStreamSuite.scala:62)
    3. org.apache.spark.streaming.kafka.JavaKafkaStreamSuite.setUp(JavaKafkaStreamSuite.java:51)
    3 frames
  5. Java RT
    Method.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    4. java.lang.reflect.Method.invoke(Method.java:606)
    4 frames
  6. JUnit
    JUnitCore.run
    1. org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
    2. org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
    3. org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
    4. org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
    5. org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:30)
    6. org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
    7. org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
    8. org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
    9. org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
    10. org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
    11. org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
    12. org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
    13. org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
    14. org.junit.runners.ParentRunner.run(ParentRunner.java:300)
    15. org.junit.runners.Suite.runChild(Suite.java:128)
    16. org.junit.runners.Suite.runChild(Suite.java:24)
    17. org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
    18. org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
    19. org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
    20. org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
    21. org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
    22. org.junit.runners.ParentRunner.run(ParentRunner.java:300)
    23. org.junit.runner.JUnitCore.run(JUnitCore.java:157)
    24. org.junit.runner.JUnitCore.run(JUnitCore.java:136)
    24 frames
  7. JUnit-Interface
    JUnitRunner.run
    1. com.novocode.junit.JUnitRunner.run(JUnitRunner.java:90)
    1 frame
  8. SBT
    ForkMain$Run$2.call
    1. sbt.RunnerWrapper$1.runRunner2(FrameworkWrapper.java:223)
    2. sbt.RunnerWrapper$1.execute(FrameworkWrapper.java:236)
    3. sbt.ForkMain$Run$2.call(ForkMain.java:294)
    4. sbt.ForkMain$Run$2.call(ForkMain.java:284)
    4 frames
  9. Java RT
    Thread.run
    1. java.util.concurrent.FutureTask.run(FutureTask.java:262)
    2. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    3. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    4. java.lang.Thread.run(Thread.java:745)
    4 frames