有谁知道如何使用logstash exec输出插件在后台运行命令? 我想这个配置使用logstash exec输出插件在后台运行命令
input {
file {
path => "file.log"
}
}
output {
exec {
command => "./script.sh fff ggg hhh jjj kkk &"
}
}
和文字内容是
#/bin/bash
echo "$*" >> file.txt
所以最后file.txt的包含&
,因为它是参数:fff ggg hhh jjj kkk &