I am trying to run Metricbeat using docker as a "sidecar" container in an ECS Fargate Task. Unfortunately when running inside Fargate containers cannot mount volumes on the host such as the /var/run/docker.sock required by metricbeat.
What is the recommended way to ship logs and metrics from my ECS containers to Elastic Search?
@Zachary_Baxter I have been striking out trying to get some help on this topic, was hoping you might be able to point me in the right direction.
I’m trying to get container metrics and logs shipped to elastic. Problem is these containers are running in AWS ECS fargate.
ECS Fargate doesn't allow host volume mounting, so we cannot mount /var/run/docker.sock or /var/lib/docker/containers. This means filebeat and metrcibeat cannot get access to the data needed to ship to elastic.
I tried to find the recommended approach to shipping logs and metrics to elasticsearch when using ECS with fargate, I found nothing.
Before I go off and create some custom beat or the overhead of passing things through cloudwatch and lambda I wanted to see what the experts recommended.
For any folks using Fargate... The feedback I am getting from the team at Elastic is to use Functionbeat for logs and then to follow the same technique Data Dog uses (https://docs.datadoghq.com/integrations/ecs_fargate/).
I was able to setup functionbeat to get my container logs shipped to elastic from fargate. This is working really great with some reasonable latencies. I'm seeing 1-5 second latencies between log time and ingest time with the default settings.
@masterxavierfox unfortunately I was pulled off onto a higher priority task. I probably wont be back on this for a few weeks. But I'd love to share resources, I will definitely put anything I come up with on github so we can collaborate on it.
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.