java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042

GitHub | cwoodworth | 5 months ago
  1. 0

    Failed to open native connection to Cassandra at {127.0.0.1}:9042

    GitHub | 5 months ago | cwoodworth
    java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042
  2. 0

    {noformat} ctool launch test 3 ctool install -t http://10.0.0.103/~pkolaczk/dse-4.8.0-SNAPSHOT-bin.tar.gz -k 1 test enterprise ctool start test enterprise export IT_TEST_CASSANDRA_HOSTS=192.168.123.10 export IT_TEST_CASSANDRA_PORTS=9042 sbt it:test {noformat} {noformat} [info] CassandraDataSourceSpec: [info] Exception encountered when attempting to run a suite with class name: com.datastax.spark.connector.sql.CassandraDataSourceSpec *** ABORTED *** (11 milliseconds) [info] java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042 [info] at com.datastax.spark.connector.cql.CassandraConnector$.com$datastax$spark$connector$cql$CassandraConnector$$createSession(CassandraConnector.scala:155) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.RefCountedCache.createNewValueAndKeys(RefCountedCache.scala:31) [info] at com.datastax.spark.connector.cql.RefCountedCache.acquire(RefCountedCache.scala:56) [info] at com.datastax.spark.connector.cql.CassandraConnector.openSession(CassandraConnector.scala:73) [info] at com.datastax.spark.connector.cql.CassandraConnector.withSessionDo(CassandraConnector.scala:101) [info] at com.datastax.spark.connector.cql.CassandraConnector.withClusterDo(CassandraConnector.scala:112) [info] at com.datastax.spark.connector.cql.Schema$.fromCassandra(Schema.scala:243) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation.<init>(CassandraSourceRelation.scala:39) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation$.apply(CassandraSourceRelation.scala:168) [info] at org.apache.spark.sql.cassandra.DefaultSource.createRelation(DefaultSource.scala:57) [info] at org.apache.spark.sql.sources.ResolvedDataSource$.apply(ddl.scala:219) [info] at org.apache.spark.sql.sources.CreateTempTableUsing.run(ddl.scala:308) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzycompute(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.execute(commands.scala:64) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLContext.scala:1099) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scala:1099) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:147) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:130) [info] at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51) [info] at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:933) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.createTempTable(CassandraDataSourceSpec.scala:50) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:38) [info] at org.scalatest.BeforeAndAfterAll$class.beforeAll(BeforeAndAfterAll.scala:187) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.BeforeAndAfterAll$class.run(BeforeAndAfterAll.scala:253) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.run(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.tools.Framework.org$scalatest$tools$Framework$$runSuite(Framework.scala:466) [info] at org.scalatest.tools.Framework$ScalaTestTask.execute(Framework.scala:677) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:294) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:284) [info] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [info] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [info] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [info] at java.lang.Thread.run(Thread.java:745) [info] Cause: com.datastax.driver.core.exceptions.NoHostAvailableException: All host(s) tried for query failed (tried: /127.0.0.1:9042 (com.datastax.driver.core.TransportException: [/127.0.0.1:9042] Cannot connect)) [info] at com.datastax.driver.core.ControlConnection.reconnectInternal(ControlConnection.java:223) [info] at com.datastax.driver.core.ControlConnection.connect(ControlConnection.java:78) [info] at com.datastax.driver.core.Cluster$Manager.init(Cluster.java:1230) [info] at com.datastax.driver.core.Cluster.getMetadata(Cluster.java:333) [info] at com.datastax.spark.connector.cql.CassandraConnector$.com$datastax$spark$connector$cql$CassandraConnector$$createSession(CassandraConnector.scala:148) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.RefCountedCache.createNewValueAndKeys(RefCountedCache.scala:31) [info] at com.datastax.spark.connector.cql.RefCountedCache.acquire(RefCountedCache.scala:56) [info] at com.datastax.spark.connector.cql.CassandraConnector.openSession(CassandraConnector.scala:73) [info] at com.datastax.spark.connector.cql.CassandraConnector.withSessionDo(CassandraConnector.scala:101) [info] at com.datastax.spark.connector.cql.CassandraConnector.withClusterDo(CassandraConnector.scala:112) [info] at com.datastax.spark.connector.cql.Schema$.fromCassandra(Schema.scala:243) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation.<init>(CassandraSourceRelation.scala:39) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation$.apply(CassandraSourceRelation.scala:168) [info] at org.apache.spark.sql.cassandra.DefaultSource.createRelation(DefaultSource.scala:57) [info] at org.apache.spark.sql.sources.ResolvedDataSource$.apply(ddl.scala:219) [info] at org.apache.spark.sql.sources.CreateTempTableUsing.run(ddl.scala:308) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzycompute(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.execute(commands.scala:64) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLContext.scala:1099) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scala:1099) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:147) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:130) [info] at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51) [info] at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:933) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.createTempTable(CassandraDataSourceSpec.scala:50) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:38) [info] at org.scalatest.BeforeAndAfterAll$class.beforeAll(BeforeAndAfterAll.scala:187) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.BeforeAndAfterAll$class.run(BeforeAndAfterAll.scala:253) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.run(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.tools.Framework.org$scalatest$tools$Framework$$runSuite(Framework.scala:466) [info] at org.scalatest.tools.Framework$ScalaTestTask.execute(Framework.scala:677) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:294) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:284) [info] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [info] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [info] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [info] at java.lang.Thread.run(Thread.java:745) {noformat}

    DataStax JIRA | 2 years ago | Piotr Kołaczkowski
    java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042
  3. 0

    {noformat} ctool launch test 3 ctool install -t http://10.0.0.103/~pkolaczk/dse-4.8.0-SNAPSHOT-bin.tar.gz -k 1 test enterprise ctool start test enterprise export IT_TEST_CASSANDRA_HOSTS=192.168.123.10 export IT_TEST_CASSANDRA_PORTS=9042 sbt it:test {noformat} {noformat} [info] CassandraDataSourceSpec: [info] Exception encountered when attempting to run a suite with class name: com.datastax.spark.connector.sql.CassandraDataSourceSpec *** ABORTED *** (11 milliseconds) [info] java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042 [info] at com.datastax.spark.connector.cql.CassandraConnector$.com$datastax$spark$connector$cql$CassandraConnector$$createSession(CassandraConnector.scala:155) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.RefCountedCache.createNewValueAndKeys(RefCountedCache.scala:31) [info] at com.datastax.spark.connector.cql.RefCountedCache.acquire(RefCountedCache.scala:56) [info] at com.datastax.spark.connector.cql.CassandraConnector.openSession(CassandraConnector.scala:73) [info] at com.datastax.spark.connector.cql.CassandraConnector.withSessionDo(CassandraConnector.scala:101) [info] at com.datastax.spark.connector.cql.CassandraConnector.withClusterDo(CassandraConnector.scala:112) [info] at com.datastax.spark.connector.cql.Schema$.fromCassandra(Schema.scala:243) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation.<init>(CassandraSourceRelation.scala:39) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation$.apply(CassandraSourceRelation.scala:168) [info] at org.apache.spark.sql.cassandra.DefaultSource.createRelation(DefaultSource.scala:57) [info] at org.apache.spark.sql.sources.ResolvedDataSource$.apply(ddl.scala:219) [info] at org.apache.spark.sql.sources.CreateTempTableUsing.run(ddl.scala:308) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzycompute(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.execute(commands.scala:64) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLContext.scala:1099) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scala:1099) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:147) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:130) [info] at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51) [info] at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:933) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.createTempTable(CassandraDataSourceSpec.scala:50) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:38) [info] at org.scalatest.BeforeAndAfterAll$class.beforeAll(BeforeAndAfterAll.scala:187) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.BeforeAndAfterAll$class.run(BeforeAndAfterAll.scala:253) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.run(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.tools.Framework.org$scalatest$tools$Framework$$runSuite(Framework.scala:466) [info] at org.scalatest.tools.Framework$ScalaTestTask.execute(Framework.scala:677) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:294) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:284) [info] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [info] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [info] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [info] at java.lang.Thread.run(Thread.java:745) [info] Cause: com.datastax.driver.core.exceptions.NoHostAvailableException: All host(s) tried for query failed (tried: /127.0.0.1:9042 (com.datastax.driver.core.TransportException: [/127.0.0.1:9042] Cannot connect)) [info] at com.datastax.driver.core.ControlConnection.reconnectInternal(ControlConnection.java:223) [info] at com.datastax.driver.core.ControlConnection.connect(ControlConnection.java:78) [info] at com.datastax.driver.core.Cluster$Manager.init(Cluster.java:1230) [info] at com.datastax.driver.core.Cluster.getMetadata(Cluster.java:333) [info] at com.datastax.spark.connector.cql.CassandraConnector$.com$datastax$spark$connector$cql$CassandraConnector$$createSession(CassandraConnector.scala:148) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:141) [info] at com.datastax.spark.connector.cql.RefCountedCache.createNewValueAndKeys(RefCountedCache.scala:31) [info] at com.datastax.spark.connector.cql.RefCountedCache.acquire(RefCountedCache.scala:56) [info] at com.datastax.spark.connector.cql.CassandraConnector.openSession(CassandraConnector.scala:73) [info] at com.datastax.spark.connector.cql.CassandraConnector.withSessionDo(CassandraConnector.scala:101) [info] at com.datastax.spark.connector.cql.CassandraConnector.withClusterDo(CassandraConnector.scala:112) [info] at com.datastax.spark.connector.cql.Schema$.fromCassandra(Schema.scala:243) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation.<init>(CassandraSourceRelation.scala:39) [info] at org.apache.spark.sql.cassandra.CassandraSourceRelation$.apply(CassandraSourceRelation.scala:168) [info] at org.apache.spark.sql.cassandra.DefaultSource.createRelation(DefaultSource.scala:57) [info] at org.apache.spark.sql.sources.ResolvedDataSource$.apply(ddl.scala:219) [info] at org.apache.spark.sql.sources.CreateTempTableUsing.run(ddl.scala:308) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzycompute(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(commands.scala:54) [info] at org.apache.spark.sql.execution.ExecutedCommand.execute(commands.scala:64) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLContext.scala:1099) [info] at org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scala:1099) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:147) [info] at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:130) [info] at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51) [info] at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:933) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.createTempTable(CassandraDataSourceSpec.scala:50) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:38) [info] at org.scalatest.BeforeAndAfterAll$class.beforeAll(BeforeAndAfterAll.scala:187) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.beforeAll(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.BeforeAndAfterAll$class.run(BeforeAndAfterAll.scala:253) [info] at com.datastax.spark.connector.sql.CassandraDataSourceSpec.run(CassandraDataSourceSpec.scala:12) [info] at org.scalatest.tools.Framework.org$scalatest$tools$Framework$$runSuite(Framework.scala:466) [info] at org.scalatest.tools.Framework$ScalaTestTask.execute(Framework.scala:677) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:294) [info] at sbt.ForkMain$Run$2.call(ForkMain.java:284) [info] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [info] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [info] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [info] at java.lang.Thread.run(Thread.java:745) {noformat}

    DataStax JIRA | 2 years ago | Piotr Kołaczkowski
    java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    GitHub comment 69#170299706

    GitHub | 11 months ago | femibyte
    java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042
  6. 0

    GitHub comment 24#201479731

    GitHub | 8 months ago | gkericks
    java.io.IOException: Failed to open native connection to Cassandra at {127.0.0.1}:9042

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.io.IOException

      Failed to open native connection to Cassandra at {127.0.0.1}:9042

      at com.datastax.spark.connector.cql.CassandraConnector$.com$datastax$spark$connector$cql$CassandraConnector$$createSession()
    2. spark-cassandra-connector
      CassandraConnector$$anonfun$2.apply
      1. com.datastax.spark.connector.cql.CassandraConnector$.com$datastax$spark$connector$cql$CassandraConnector$$createSession(CassandraConnector.scala:164)
      2. com.datastax.spark.connector.cql.CassandraConnector$$anonfun$2.apply(CassandraConnector.scala:150)
      2 frames