If you can get the correct command and parse it you can do it with logstash exec input plugin. Now you just need to find which command works for your OS. For instance on Linux you can use ls | wc -l to get the file count of a folder.
So you have to create a process that writes the answer to a file, and then consume that file into elastic, for that to the read the contents and process accordingly?
If that is correct then when the file is overwritten with the new value then does elastic know that the value has changed, or do you have to create a new file each time?
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.