Skip to content

Instantly share code, notes, and snippets.

@gt50
Created October 24, 2014 02:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gt50/7bde16dd328dd49782ce to your computer and use it in GitHub Desktop.
Save gt50/7bde16dd328dd49782ce to your computer and use it in GitHub Desktop.
pacs.conf
input {
tcp {
type => "pacs"
port => 3517
}
}
filter {
if [type] == "pacs" {
grok {
match => ["message", "%{TIMESTAMP_ISO8601:timestamp} %{WORD:loglevel} %{SYSLOG5424SD:logsource} \(Import:%{GREEDYDATA:studyuid}\) %{GREEDYDATA:action} Patient:%{GREEDYDATA:patienname}, PatientID:%{GREEDYDATA:patientid}, IPID:%{WORD:ipid}, Modality:%{WORD:modality}, Accession:%{WORD:accession}, StudyDate:%{YEAR:dosyear}%{MONTHNUM:dosmonth}%{MONTHDAY:dosday}"]
match => ["message", "%{TIMESTAMP_ISO8601:timestamp} %{WORD:loglevel} %{SYSLOG5424SD:logsource} \(InImageQueueEventGenerator\) %{GREEDYDATA:action} Patient:%{GREEDYDATA:patienname}, PatientID:%{GREEDYDATA:patientid}, IPID:%{WORD:ipid}, Modality:%{WORD:modality}, Accession:%{WORD:accession}, StudyDate:%{YEAR:dosyear}%{MONTHNUM:dosmonth}%{MONTHDAY:dosday}"]
}
date {
match => [ "timestamp", "YYYY-MM-dd HH:mm:ss,SSS" ]
timezone => "America/Los_Angeles"
}
}
}
output {
if [type] == "pacs" {
elasticsearch { host => localhost }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment