0 votes
198 views
in Networking by
edited

I would like to get your input on an error I am trying to debug with elastiflow collector.
Setup:
I have elastiflow collector v6.1.1 running on a single node VM as a docker container. I tried enabling EF_OUTPUT_ELASTICSEARCH_ENABLE to check if flow records (sflow, netflow) sent to the collector can be outputted to the elasticsearch instance running on the same node. (deployed using elastic helm charts).
Following are the configs set related to elasticsearch on elastiflow’s docker-compose:

   # Elasticsearch
      EF_OUTPUT_ELASTICSEARCH_ENABLE: 'true'
      EF_OUTPUT_ELASTICSEARCH_ECS_ENABLE: 'true'
      EF_OUTPUT_ELASTICSEARCH_BATCH_DEADLINE: 2000
      EF_OUTPUT_ELASTICSEARCH_BATCH_MAX_BYTES: 8388608
      EF_OUTPUT_ELASTICSEARCH_TIMESTAMP_SOURCE: 'end'
      EF_OUTPUT_ELASTICSEARCH_INDEX_PERIOD: 'daily'
      EF_OUTPUT_ELASTICSEARCH_INDEX_TEMPLATE_ENABLE: 'true'
      EF_OUTPUT_ELASTICSEARCH_INDEX_TEMPLATE_OVERWRITE: 'true'
      EF_OUTPUT_ELASTICSEARCH_INDEX_TEMPLATE_SHARDS: 1
      EF_OUTPUT_ELASTICSEARCH_INDEX_TEMPLATE_REPLICAS: 0

Error:
logs in the elastiflow container pertain to an error while inserting component templates which reads:

{"level":"error","ts":"2022-12-16T16:55:18.502Z","logger":"component_template_manager","caller":"templates/handler_component.go:85","msg":"error inserting chunk of component templates retrying in 500 milliseconds - error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-path-codex-hop-2.1\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-flow-ecs-agent-8.0\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-path-codex-sec-2.1\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-path-ecs-host-2.1\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-path-codex-app-2.1\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-path-codex-l4-2.1\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-flow-ecs-client-8.0\": EOF; error on put component template request - Put \"http://127.0.0.1:31071/_component_template/elastiflow-path-ecs-codex-flow-2.1\": EOF","stacktrace":"github.com/elastiflow/flowcoll/pkg/outputs/utils/templates.insertComponentTemplatesByChunks\n\t/tmp/flowcoll/pkg/outputs/utils/templates/handler_component.go:85\ngithub.com/elastiflow/flowcoll/pkg/outputs/utils/templates.(*ManageComponentTemplate).HandleComponentTemplates\n\t/tmp/flowcoll/pkg/outputs/utils/templates/handler_component.go:49\ngithub.com/elastiflow/flowcoll/pkg/outputs/elasticsearch.(*Bootstrap).bootstrap\n\t/tmp/flowcoll/pkg/outputs/elasticsearch/bootstrap.go:149\ngithub.com/elastiflow/flowcoll/pkg/outputs/elasticsearch.(*Bootstrap).Run\n\t/tmp/flowcoll/pkg/outputs/elasticsearch/bootstrap.go:122\ngithub.com/elastiflow/flowcoll/pkg/outputs/elasticsearch.NewCreateInstanceFunc.func1\n\t/tmp/flowcoll/pkg/outputs/elasticsearch/instance_registration.go:101\ngithub.com/elastiflow/flowcoll/pkg/instantiator.(*Instantiator).Run\n\t/tmp/flowcoll/pkg/instantiator/instantiator.go:74"}

Can you please help provide more context on how I can fix this error?

1 Answer

0 votes
by
Looks like mismatched TLS settings. You did not configure the collector to connect to Elasticsearch using TLS. However, your Elasticsearch instance may be using TLS
...