Hi Team,
How to find Elasticsearch endpoint in order to send data to the server for testing?
Thanks in advance
How to find Elasticsearch Endpoint?
Re: How to find Elasticsearch Endpoint?
Hello @SuryanuSanyal
Thanks for reaching out, want to present the option to call out via API to get the list idices and then retrieve info from specific logstash:
Example list:
Example results:
Perry
Thanks for reaching out, want to present the option to call out via API to get the list idices and then retrieve info from specific logstash:
Code: Select all
curl -X GET "localhost:9200/_aliases/0?pretty"Then run query on "logstash-2021.08.01" example:{
"my-index-000001" : {
"aliases" : { }
},
"nagioslogserver_log" : {
"aliases" : { }
},
"logstash-2021.07.31" : {
"aliases" : { }
},
"logstash-2021.08.01" : {
"aliases" : { }
},
Code: Select all
curl -X GET "localhost:9200/logstash-2021.07.31/_search?pretty"Please let us know how things look,"_index" : "logstash-2021.07.31",
"_type" : "syslog",
"_id" : "AXr53TX6wCTTPdRqeG_S",
"_score" : 1.0,
"_source":{"message":"pam_unix(sudo:session): session opened for user root by (uid=0)\n","@version":"1","@timestamp":"2021-07-31T00:01:01.000Z","type":"syslog","host":"0:0:0:0:0:0:0:1","priority":86,"timestamp":"Jul 30 19:01:01","logsource":"localhost",
Perry