2014-03-13 72 views
3

我想指定ElasticSearch用于HTTP通信的确切端口。我该怎么做?在配置文件中,它表示默认监听端口范围。我怎样才能限制这个端口范围只有1个端口?ElasticSearch - 指定确切的端口(无端口范围)

Elasticsearch, by default, binds itself to the 0.0.0.0 address, and listens 
on port [9200-9300] for HTTP traffic and on port [9300-9400] for node-to-node 
communication. (the range means that if the port is busy, it will automatically 
try the next port). 

回答

3

在config文件夹中有一个名为“elasticsearch.Yml”的文件。在港口的评论说, 参数..就在http.port删除哈希和端口值添加到它..

http.port : 5000 

您可以同时为TCP和HTTP

做到这一点