Fluentd

groundcover supports ingestion of logs from Fluentd collectors. This page will guide you to configure your Fluentd collector to send logs it has collected to your groundcover installation.

This feature is only available for enterprise plan.

We currently only supports ingesting logs from FluentD. If you would like to ingest something else, let us know over Slack.

Setting metadata

While not required, it is suggested to set metadata attributes to be recognized by groundoover.

Attribute
Meaning

env_name

Will associate the log with an environment in groundcover. Read more

clusterId

Will associate the log with a cluster in groundcover.

host.name

Will appear as the logs' hostname

gc_source_type

will appear the source of the type of the logs. . Can be any value of your choosing. For example, logs from Kubernetes clusters are marked as 'k8s'

service.name

Will appear as the name of the workload that created the log.

For example:

<filter **>
  @type record_transformer
  <record>
    host.name "#{Socket.gethostname}"
    env_name "production" # Adjust based on your environment
    clusterId "prod-1"
    gc_source_type "host"
    service.name "server-app"
  </record>
</filter>

Configuring HTTP output to groundcover

We will use Fluentd's HTTP output plugin to send the logs to groundcover.

Finding the endpoint of the inCloud backend

Use these docs to find your inCloud's JSON logs endpoint, and make sure you have your API key. It should look something like this: https://<your-incloud-site>/json/logs

Configuring an output stage

Add this output plugin to your Fluentd configuration:

<match server.logs>
  @type http
  endpoint <inCloud_json_logs_endpoint>
  headers {"apikey": <ingestion_key>}
  http_method post
  <format>
    @type json
  </format>
</match>

You can adjust further settings like buffer as described in the plugin's documentation.

Viewing your logs

Access the groundcover platform and you should see your logs in the log page. We recommend looking based on the attributes previously set:

  • source can be used with the gc_source_typeattribute

  • env can be used with the env_nameattribute

  • workload can be used with the service.nameattribute

Last updated