I've been using metricbeat and filebeat and it works well and I'm trying to use exec plugin to run a command (netstat...) on certain nodes only. I have 4 different types of remote nodes I'm ingesting data from and I want to get the data from exec from just one of them. What's the best way of doing this?
command => 'netstat -anp | grep ":10011"'
interval => 20
type => 'netstat'
I've done it differently before where I have a script running on the remote server of that particular type and it generate a file with the output data and then I ingest that file using filebeat. Using exec plugin seems cleaner though.