【问题标题】:Can I ingest zipped data using Logstash?我可以使用 Logstash 提取压缩数据吗?
【发布时间】:2017-01-03 07:03:21
【问题描述】:

我正在尝试将数据提取到 Elasticsearch。

数据位于共享文件夹中。如果可能的话,我想在将 zip 文件摄取到 Elasticsearch 后删除它。

这是一个 .zip 文件,它解压缩成一个大的单个文件,格式如下:

#ReferenceID    123das
#FamilyID       abc
#ArchiveDate    1483237892226   (datetime in millisecond epoch)
#SenderID       user1 
#RecipientID    user2 
#RecipientID    user3   (notice there are more than 1 RecipientID)
#Content        
This is secret content of the document, and it is not encrypted. 
#EndDoc

#ReferenceID    123das/1  (The "/1" means 1st attachment)
#FamilyID       abc        
#ArchiveDate    1483237892227   (datetime in millisecond epoch)
#SenderID       user1 
#RecipientID    user2 
#RecipientID    user3   (notice there are more than 1 RecipientID)
#Content        
This is the secret attachment content  
#EndDoc

#ReferenceID...
...
#EndDoc 

...multiple of these until End of File 

基本上每个

#ReferenceID... 
...
#EndDoc

表示要摄取到 Elasticsearch 中的文档

我的问题是这可以使用 Logstash 和 Beats 完成吗?我该怎么做呢?任何指针表示赞赏。

【问题讨论】:

    标签: elasticsearch logstash filebeat


    【解决方案1】:

    Logstash 的文件{} 输入无法处理压缩文件。请参阅github issue

    Filebeat 也不能​​……但是!请参阅this PR,它似乎正在通过。

    仅供参考,s3{} 输入可以。

    【讨论】:

    • 谢谢阿兰!我来看看s3
    猜你喜欢
    • 1970-01-01
    • 2011-09-01
    • 2010-12-16
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2010-12-13
    • 2010-11-29
    • 1970-01-01
    相关资源
    最近更新 更多