Hi everyone, I'm trying to export AWS Cloudwatch logs to Logstash input plugin. However, I get an error message saying "Failed to execute action...".
[pipeline.conf file]:
input{
cloudwatch {
namespace => "AWS/Logs"
metrics => [""] # ?
filters => {"logStream:myGroupName" => "myStreamName"} # ?
log_group => "myGroupName"
access_key_id => "...id..."
secret_access_key => "...secret..."
region => "us-west-2"
}
}
output{
stdout{
codec => rubydebug
}
}
[Error Message]:
./bin/logstash -f config/pipelines/cloudwatchPipeline.conf --config.reload.automatic
OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.headius.backport9.modules.Modules (file:/home/kourosh/Documents/logstash-7.0.1/logstash-core/lib/jars/jruby-complete-9.2.7.0.jar) to field java.io.FileDescriptor.fd
WARNING: Please consider reporting this to the maintainers of com.headius.backport9.modules.Modules
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
Sending Logstash logs to /home/kourosh/Documents/logstash-7.0.1/logs which is now configured via log4j2.properties
[2019-05-24T09:04:29,375][WARN ][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules or command line options are specified
[2019-05-24T09:04:29,383][INFO ][logstash.runner ] Starting Logstash {"logstash.version"=>"7.0.1"}
[2019-05-24T09:04:30,856][ERROR][logstash.inputs.cloudwatch] Unknown setting 'log_group' for cloudwatch
[2019-05-24T09:04:30,862][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"LogStash::ConfigurationError", :message=>"Something is wrong with your configuration.", :backtrace=>["/home/kourosh/Documents/logstash-7.0.1/logstash-core/lib/logstash/config/mixin.rb:86:in config_init'", "/home/kourosh/Documents/logstash-7.0.1/logstash-core/lib/logstash/inputs/base.rb:60:in
initialize'", "org/logstash/plugins/PluginFactoryExt.java:255:in plugin'", "org/logstash/plugins/PluginFactoryExt.java:117:in
buildInput'", "org/logstash/execution/JavaBasePipelineExt.java:50:in initialize'", "/home/kourosh/Documents/logstash-7.0.1/logstash-core/lib/logstash/java_pipeline.rb:23:in
initialize'", "/home/kourosh/Documents/logstash-7.0.1/logstash-core/lib/logstash/pipeline_action/create.rb:36:in execute'", "/home/kourosh/Documents/logstash-7.0.1/logstash-core/lib/logstash/agent.rb:325:in
block in converge_state'"]}
[2019-05-24T09:04:31,070][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9601}
[2019-05-24T09:04:34,035][ERROR][logstash.inputs.cloudwatch] Unknown setting 'log_group' for cloudwatch