"message":"No living connections","node_env":"production"
"message":"No living connections","node_env":"production"
我正在尝试在我的机器上安装 Kibana 4,但出现以下错误。
{"@timestamp":"2015-04-15T06:25:50.688Z","level":"error","node_env":"production","error":"Request error, retrying -- connect ECONNREFUSED"}
{"@timestamp":"2015-04-15T06:25:50.693Z","level":"warn","message":"Unable to revive connection: http://0.0.0.0:9200/","node_env":"production"}
{"@timestamp":"2015-04-15T06:25:50.693Z","level":"warn","message":"No living connections","node_env":"production"}
{"@timestamp":"2015-04-15T06:25:50.698Z","level":"fatal","message":"No Living connections","node_env":"production","error":{"message":"No Living connections","name":"Error","stack":"Error: No Living connections\n at sendReqWithConnection (/home/kibana-4.0.0-rc1-linux-x64/src/node_modules/elasticsearch/src/lib/transport.js:174:15)\n
ECONNREFUSED
告诉您它无法连接到 Elasticsearch。 http://0.0.0.0:9200/
告诉您它正在尝试连接什么。
您需要修改 config/kibana.yml
并更改 elasticsearch_url
设置以指向您的集群。如果你是运行同框上的Elasticsearch,正确的值为http://localhost:9200
.
您的弹性搜索已关闭。
就我而言,这是因为未设置环境变量 Java_Home
correctly.You 必须手动设置。这些是执行此操作的指南:
转到您的 PC 环境。
新建一个变量,变量名Java_Home
。变量值应该是java安装路径
确保你的路径没有空格。如果您的 Java 在 Program Files(x86) 中,您可以使用以下快捷方式:progra~2
而不是 Program Files(x86)
。
结果你有这样的东西:C:\Progra~2\Java\jre1.8.0_131
在您使用 AWS Elasticsearch 服务的情况下,发生这种情况还有另一个原因。
没有ES的授权访问策略和没有加载正确的AWS凭证将是根本原因。
还有一种可能,也许你的 elasticsearch 没有按照你的意愿 运行 正确:请检查 this link 并尝试 dockerize elasticsearch。
对我来说这个 docker-compose.yml 文件可以 docker 化 elasticsearch:
services:
elasticsearch:
image: "${CREATED_IMAGE_NAME_PREFIX}:1"
container_name: efk_elastic
build:
context: ./elasticsearch
args:
EFK_VERSION: $EFK_VERSION
ELASTIC_PORT1: $ELASTIC_PORT1
ELASTIC_PORT2: $ELASTIC_PORT2
environment:
# node.name: node
# cluster.name: elasticsearch-default
ES_JAVA_OPTS: -Xms1g -Xmx1g
discovery.type: single-node
ELASTIC_PASSWORD: changeme
http.cors.enabled: "true"
http.cors.allow-credentials: "true"
http.cors.allow-headers: X-Requested-With,X-Auth-Token,Content-Type,Content-Length,Authorization
http.cors.allow-origin: /https?:\/\/localhost(:[0-9]+)?/
hostname: elasticsearch
ports:
- "${ELASTIC_EXPOSED_PORT1}:$ELASTIC_PORT1"
- "$ELASTIC_EXPOSED_PORT2:${ELASTIC_PORT2}"
volumes:
# - type: bind
# source: ./elasticsearch/config/elasticsearch.yml
# target: /usr/share/elasticsearch/config/elasticsearch.yml
# read_only: true
- type: volume
source: elasticsearch_data
target: /usr/share/elasticsearch/data
networks:
- efk
请注意,这并不完整。有关详细信息,请参阅我的 GitHub repository
我正在尝试在我的机器上安装 Kibana 4,但出现以下错误。
{"@timestamp":"2015-04-15T06:25:50.688Z","level":"error","node_env":"production","error":"Request error, retrying -- connect ECONNREFUSED"}
{"@timestamp":"2015-04-15T06:25:50.693Z","level":"warn","message":"Unable to revive connection: http://0.0.0.0:9200/","node_env":"production"}
{"@timestamp":"2015-04-15T06:25:50.693Z","level":"warn","message":"No living connections","node_env":"production"}
{"@timestamp":"2015-04-15T06:25:50.698Z","level":"fatal","message":"No Living connections","node_env":"production","error":{"message":"No Living connections","name":"Error","stack":"Error: No Living connections\n at sendReqWithConnection (/home/kibana-4.0.0-rc1-linux-x64/src/node_modules/elasticsearch/src/lib/transport.js:174:15)\n
ECONNREFUSED
告诉您它无法连接到 Elasticsearch。 http://0.0.0.0:9200/
告诉您它正在尝试连接什么。
您需要修改 config/kibana.yml
并更改 elasticsearch_url
设置以指向您的集群。如果你是运行同框上的Elasticsearch,正确的值为http://localhost:9200
.
您的弹性搜索已关闭。
就我而言,这是因为未设置环境变量 Java_Home
correctly.You 必须手动设置。这些是执行此操作的指南:
转到您的 PC 环境。
新建一个变量,变量名
Java_Home
。变量值应该是java安装路径确保你的路径没有空格。如果您的 Java 在 Program Files(x86) 中,您可以使用以下快捷方式:
progra~2
而不是Program Files(x86)
。
结果你有这样的东西:C:\Progra~2\Java\jre1.8.0_131
在您使用 AWS Elasticsearch 服务的情况下,发生这种情况还有另一个原因。
没有ES的授权访问策略和没有加载正确的AWS凭证将是根本原因。
还有一种可能,也许你的 elasticsearch 没有按照你的意愿 运行 正确:请检查 this link 并尝试 dockerize elasticsearch。
对我来说这个 docker-compose.yml 文件可以 docker 化 elasticsearch:
services:
elasticsearch:
image: "${CREATED_IMAGE_NAME_PREFIX}:1"
container_name: efk_elastic
build:
context: ./elasticsearch
args:
EFK_VERSION: $EFK_VERSION
ELASTIC_PORT1: $ELASTIC_PORT1
ELASTIC_PORT2: $ELASTIC_PORT2
environment:
# node.name: node
# cluster.name: elasticsearch-default
ES_JAVA_OPTS: -Xms1g -Xmx1g
discovery.type: single-node
ELASTIC_PASSWORD: changeme
http.cors.enabled: "true"
http.cors.allow-credentials: "true"
http.cors.allow-headers: X-Requested-With,X-Auth-Token,Content-Type,Content-Length,Authorization
http.cors.allow-origin: /https?:\/\/localhost(:[0-9]+)?/
hostname: elasticsearch
ports:
- "${ELASTIC_EXPOSED_PORT1}:$ELASTIC_PORT1"
- "$ELASTIC_EXPOSED_PORT2:${ELASTIC_PORT2}"
volumes:
# - type: bind
# source: ./elasticsearch/config/elasticsearch.yml
# target: /usr/share/elasticsearch/config/elasticsearch.yml
# read_only: true
- type: volume
source: elasticsearch_data
target: /usr/share/elasticsearch/data
networks:
- efk
请注意,这并不完整。有关详细信息,请参阅我的 GitHub repository