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
- list-style:none outside none;的作用NoneIDE
- Swap Nodes in PairsAI
- python使用pip安裝模組出錯 Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None))PythonNone
- No CurrentSessionContext configuredSessionContext
- 13-Architecture-nodes
- 024,Swap Nodes in PairsAI
- 24. Swap Nodes in PairsAI
- The best LeetCode NodesLeetCode
- Etag和if-None-MatchNone
- docker network之 noneDockerNone
- RUST Some None 和OKRustNone
- Docker這些none:none的映象,難道就不配擁有名字嗎DockerNone
- quit(code=None)函式和exit(code=None)函式的使用舉例UINone函式
- Leetcode Swap Nodes in PairsLeetCodeAI
- InputStream之available()AI
- No free sectors availableAI
- Servlet action is not availableServletAI
- 【SQLServer】Server ‘SERVERNAME’ is not configured for RPCSQLServerRPC
- HTTP Etag與If-None-MatchHTTPNone
- pydantic json 忽略 None 值JSONNone
- Leetcode 24 Swap Nodes in PairsLeetCodeAI
- LeetCode 24 Swap Nodes in PairsLeetCodeAI
- Leetcode-Swap Nodes in PairsLeetCodeAI
- Swap Nodes in Pairs leetcode javaAILeetCodeJava
- No bean named BookServiceImpl availableBeanAI
- hadoop原始碼解讀——ConfiguredHadoop原始碼
- Python中None如何判斷PythonNone
- Docker定時刪除none映象DockerNone
- 因touch-action: none;得mescrollNone
- WPF Stretch None,Fill,Uniform,UnformToFillNoneORM
- Leetcode Reverse Nodes in k-GroupLeetCode
- One cause leads to the error(The specified nodes are not clusterable)Error
- OCR integrity results are inconsistent amongst the nodes.
- No Task Available解決方法AI
- List Available DBCC CommandsAI
- python None與Null 的區別PythonNoneNull