Input from two csv files and compare

Hi Team,

I am planning to get the input from two csf files, assign the columns value and if the device column value match , I need the print the ip address in the output .
Please share the codes to compare and print

nput

{
file{
type => data
path => ["/home/nandha/nandha.csv","/home/nandha/test.csv"]
start_position => "beginning"
sincedb_path => "/dev/null"
}
}
filter
{
if [path] == "/home/nandha/nandha.csv"
{
csv {
separator => ","
columns => ["eventState","severity","device","count","ipAddress"]
}
}
if [path] == "/home/nandha/test.csv"
{
csv {
separator => ","
columns => ["eventStateone","severityone","deviceone","countone"]
}
}
}
output
{
stdout {
codec => rubydebug
}
}

You could lookup the IP address of the device using a translate filter. A translate filter requires a two column csv file as its input.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.