![]() ![]() The above command will generate the /tmp/output.csv file but will contain column headings for each row rather than actual data. In order to get a list of column names for each row, the following command can be run:Ĭurl -XGET ‘ template_name -*/_search?pretty’ -d ‘ -–PASTE HERE- ‘ | jq -r ‘.hits.hits._source | del(.tags) | ] | map(.key) | > /tmp/output.csv Note: Since ELK deals with unstructured data, it may be the case that the csv file does not have the same number of columns for each entry, especially if different types of records are queried. The csv output will be stored in the /tmp/output.csv file, which can be downloaded via SFTP and manipulated as necessary Note: “size” in the copy/pasted text needs to be modified according to how many records are to be exported. Open a linux terminal and use the following command, pasting the above where indicated, and changing the template name as appropriate:Ĭurl -XGET ‘ template_name -*/_search?pretty’ -d ‘ -–PASTE HERE- ‘ | jq -r ‘.hits.hits._source | del(.tags) | ] | map(.value) | > /tmp/output.csv Select “Request” and copy the request displayed:Ĥ. Expand the additional options pane by clicking on the arrow underneath the graph as indicated in the below screenshot:ģ. Run the desired query through the Kibana WebUIĢ. Note: the following requires the “jq” json parser, available from: ġ.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |