Elasticsearch NoNodeAvailableException None of the configured nodes are available
問題背景:
將es部署到內網中兩臺伺服器,其Ip地址分別為:192.111.222.5,192.111.222.1(部署方式完全一樣,是將192.111.222.1伺服器上es整個部署包,拷貝到了192.111.222.5,包括索引檔案)。
在開發本機(IP:192.111.222.36)通過idea編譯直接執行程式碼,從而連線對應es的伺服器,連線192.111.222.1就沒有任何問題,但連線192.111.222.5,就會報出異常,具體異常資訊如下:
NoNodeAvailableException[None of the configured nodes are available: [{#transport#-1}{192.111.222.5}{192.111.222.5:9300}]]
at org.elasticsearch.client.transport.TransportClientNodesService.ensureNodesAreAvailable(TransportClientNodesService.java:290)
at org.elasticsearch.client.transport.TransportClientNodesService.execute(TransportClientNodesService.java:207)
at org.elasticsearch.client.transport.support.TransportProxyClient.execute(TransportProxyClient.java:55)
at org.elasticsearch.client.transport.TransportClient.doExecute(TransportClient.java:286)
at org.elasticsearch.client.support.AbstractClient.execute(AbstractClient.java:351)
at org.elasticsearch.client.support.AbstractClient$IndicesAdmin.execute(AbstractClient.java:1187)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:85)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:59)
at org.elasticsearch.action.ActionRequestBuilder.get(ActionRequestBuilder.java:67)
解決辦法:將192.111.222.5伺服器上配置檔案elasticsearch.yml,具體位置如下
修改配置檔案中的network.host項,將network.host: 0.0.0.0修改為本機ipnetwork.host: 192.111.222.5,搞定。
具體如下:
但有個問題就是192.111.222.1配置檔案中的network.host項一直為network.host: 0.0.0.0,但可以正常訪問啊,為什麼192.111.222.5就需要修改為本機ip了?暫時沒有搞清楚,希望有知道的朋友,留個言,幫我解一下惑。
作者:jiankunking 出處:http://blog.csdn.net/jiankunking
相關文章
- pip is configured with locations that require TLS/SSL, however the ssl module in Python is not availableUITLSPythonAI
- WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.UITLSPythonAI
- The best LeetCode NodesLeetCode
- 024,Swap Nodes in PairsAI
- 13-Architecture-nodes
- python使用pip安裝模組出錯 Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None))PythonNone
- TWO NODES(HDU-4587)
- Leetcode 24 Swap Nodes in PairsLeetCodeAI
- Spring Boot Configuration Annotation Processor not configuredSpring Boot
- No instances available for XXXAI
- docker network之 noneDockerNone
- Leetcode 25 Reverse Nodes in k-GroupLeetCode
- No bean named ''XXX“ availableBeanAI
- No bean named BookServiceImpl availableBeanAI
- Etag和if-None-MatchNone
- RUST Some None 和OKRustNone
- pydantic json 忽略 None 值JSONNone
- Poster stopped: message is larger than configured max size
- Docker這些none:none的映象,難道就不配擁有名字嗎DockerNone
- quit(code=None)函式和exit(code=None)函式的使用舉例UINone函式
- [LeetCode] 2487. Remove Nodes From Linked ListLeetCodeREM
- 【Leetcode】25.Reverse Nodes in k-GroupLeetCode
- No Task Available解決方法AI
- template might not exist or might not be accessible by any of the configured Template Resolvers
- 【Bug解決】Spring Boot Configuration Annotation Processor not configuredSpring Boot
- HTTP Etag與If-None-MatchHTTPNone
- WPF Stretch None,Fill,Uniform,UnformToFillNoneORM
- Python中None如何判斷PythonNone
- [Leetcode力扣 25] Reverse Nodes in k-GroupLeetCode力扣
- Caused by:.NoSuchBeanDefinitionException: No bean named 'userInfoServiceImpl' availableBeanExceptionAI
- Docker定時刪除none映象DockerNone
- Spring:錯誤No bean named 'xxxxxxx' availableSpringBeanAI
- [20191211]Free SGA Memory Available.txtAI
- 【譯】gRPC-Web for .NET now availableRPCWebAI
- kafka 錯誤: larger than available brokersKafkaAI
- Ansible: No inventory was passed, only implicit localhost is availablelocalhostAI
- Basically Available(基本可用),Soft stateAI
- display:none和visibility:hidden的區別None
- display: none與visibility: hidden的區別None