Advertisement
Guest User

Untitled

a guest
Mar 26th, 2017
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.48 KB | None | 0 0
  1. input {
  2.     file {
  3.     path => "C:/Elk/logstash/bin/us_a_symfony.access.log-2017-02-24"
  4.     type => "apache-access"  # a type to identify those logs (will need this later)
  5.     start_position => "beginning"
  6. }
  7. }
  8.  
  9.  
  10. filter {
  11.   grok {
  12.     match => { "message" => "%{COMBINEDAPACHELOG}" }
  13.   }
  14.   date {
  15.     match => [ "timestamp" , "dd/MMM/yyyy:HH:mm:ss Z" ]
  16.   }
  17. }
  18.  
  19. output {
  20.   elasticsearch { hosts => ["localhost:9200"]
  21. index => "logi"
  22.  }
  23.   stdout { codec => rubydebug }
  24.  
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement