你只用elasticsearch还是用ELK stack(elasticsearch, logstash, kibana)?我用过ELK stack,用的logstash-forwarder把文件发送给logstash存在elasticsearch里。也许你想要的是类似 elasticsearch-knapsack