input { 
  file {
    path => ["E:/222/*.csv"]
    start_position => "beginning"
  }
}
filter {
  csv {
    separator => ","
    columns => ["tm","openid","fuwuhao","action","content"]
  }  
   date {
  
      match => ["timestamp", "yyyy-MM-dd HH:mm:ss", "ISO8601"]
 
      remove_field => ["tm"]
  
    }
  
  }

output {
  elasticsearch {
    hosts => ["http://192.168.222.222:9200"]
    index => "wx" 
  }
}

 

sincedb_path:可以是一个不存在的文件

path:windows下文件分隔如果"\",不会导入数据,也没有error信息,需要改成:"/" 

posted on 2019-12-04 09:57  默西塞德  阅读(644)  评论(0编辑  收藏  举报