什么是针对部署在google / aws云上的ES运行的titan db 1.0的正确配置

时间:2016-06-27 11:40:03

标签: elasticsearch titan

我正在使用titan 1.0,ES 1.51在内部作为服务运行(127.0.0.1),并且运行良好。

我的ES工作配置是:

    storage.backend=cassandra
    storage.hostname=cassandraserver2-cassandra-00

    cache.db-cache = true
    cache.db-cache-clean-wait = 20
    cache.db-cache-time = 180000
    cache.db-cache-size = 0.25
    query.fast-property=true

    index.search.backend=elasticsearch
    index.search.hostname=localhost
    index.search.elasticsearch.interface=NODE

现在我想将ES重新部署到云中,但不幸的是,泰坦还没有上线。

我得到的例外是:

    gremlin> tg = TitanFactory.open('../conf/titan-db.properties')
    Could not instantiate implementation: com.thinkaurelius.titan.diskstorage.es.ElasticSearchIndex
    Display stack trace? [yN] y
    java.lang.IllegalArgumentException: Could not instantiate implementation: com.thinkaurelius.titan.diskstorage.es.ElasticSearchIndex
        at com.thinkaurelius.titan.util.system.ConfigurationUtil.instantiate(ConfigurationUtil.java:55)
        at com.thinkaurelius.titan.diskstorage.Backend.getImplementationClass(Backend.java:473)
        at com.thinkaurelius.titan.diskstorage.Backend.getIndexes(Backend.java:460)
        at com.t...
Caused by: org.elasticsearch.client.transport.NoNodeAvailableException: None of the configured nodes are available: []
    at org.elasticsearch.client.transport.TransportClientNodesService.ensureNodesAreAvailable(TransportClientNodesService.java:279)
    at org.elasticsearch.client.transport.TransportClientNodesService.execute(TransportClientNodesService.java:198)
    at org.elasticsearch.client.transport.support.InternalTransportClusterAdminClient.execute(InternalTransportClusterAdminClient.java:86)

在google / aws云上针对elasticsearch服务运行的titan属性的正确配置是什么?

假设“VM”的外部ip是8.35.193.69并且我用ping到达这台机器

我正在使用titan-db属性:

storage.backend=cassandra
storage.hostname=cassandraserver2-cassandra-00

cache.db-cache = true
cache.db-cache-clean-wait = 20
cache.db-cache-time = 180000
cache.db-cache-size = 0.25
query.fast-property=true

index.search.backend=elasticsearch
index.search.hostname=8.35.193.69
index.search.client-only=true
index.search.local-mode=false
index.search.elasticsearch.interface=NODE

欢迎任何解决方案

1 个答案:

答案 0 :(得分:0)

您需要确保您的实例上的端口9300已打开。如果它没有打开,您需要:

  1. 确保ES服务已启动sudo service elasticsearch status
  2. 确保端口9300已打开并接受请求。查看here
  3. 的方式

    如果端口已关闭,则需要启用TCP传输通信。查看here

    将您的配置更改为:

    # elasticsearch config
    index.search.backend=elasticsearch
    index.search.elasticsearch.interface=TRANSPORT_CLIENT
    index.search.hostname=your_ip:9300