# Service/service\_name is coming as unknown\_service

**URL:** <https://community.grafana.com/t/service-service-name-is-coming-as-unknown-service/163160>\
**Category:** Grafana Loki\
**Created:** [June 4, 2026, 3:29pm UTC](https://community.grafana.com/t/service-service-name-is-coming-as-unknown-service/163160 "2026-06-04T15:29:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vallikanusekarart](https://avatars.discourse-cdn.com/v4/letter/v/59ef9b/32.png) [@vallikanusekarart](https://community.grafana.com/u/vallikanusekarart)\
**Post date:** [June 4, 2026, 3:29pm UTC](https://community.grafana.com/t/service-service-name-is-coming-as-unknown-service/163160/1 "2026-06-04T15:29:58Z")

</div>

Hi, we are facing srevice/service\_name = unknown\_service issue, Plugin used is fluent-plugin-grafana-loki. We tried below config in Loki chart and the other config on fluentd side, please check and advise:

Loki-chart-config:

limits\_config:  
discover\_service\_name:  
- index

Fluentd-side config:

```
        index $.index

        service_name $.index

        service $.index

      </label>

```

full fluentd loki-config:

```
  <label @REWRITTEN>

    <match \*\*>

      @type loki

      url "#{ENV\['LOKI_URL'\]}"

      ca_cert /secure/tls-certs/ca.crt

      line_format json

      

      \# FIX 1: Provide ONLY 'index' and 'valli'. 

      \# Remove 'service_name' and 'service' so Loki's chart can discover 'index' automatically.

      <label>

        valli $.index

        index $.index

        service_name $.index

        service $.index

      </label>

      \# FIX 2: Do NOT include 'remove_keys index'. 

      \# If you remove it here, Fluentd's buffer chunking breaks during evaluation.

      \# FIX 3: Keep $.index as the primary memory chunk routing key.

      <buffer $.index>

        @type memory

        flush_interval 1s

        retry_type periodic

        retry_forever false

        retry_wait 10s

        retry_max_times 2

        chunk_limit_size 8m

        total_limit_size 256MB

        overflow_action drop_oldest_chunk

        flush_thread_count 16

        queued_chunks_limit_size 32

        flush_at_shutdown true

      </buffer>

    </match>

  </label>

```

---

<div class="post-metadata">

**Author:** ![tonyswumac](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/tonyswumac/32/22401_2.png) [@tonyswumac](https://community.grafana.com/u/tonyswumac)\
**Post date:** [June 4, 2026, 8:02pm UTC](https://community.grafana.com/t/service-service-name-is-coming-as-unknown-service/163160/2 "2026-06-04T20:02:41Z")

</div>

If you are using fluentd, pretty sure you beed one label block per label. For example:

```auto
<label>
  valli $.index
</label>

<label>
  index $.index
</label>

<label>
  service_name $.index
</label>

<label>
  service $.index
</label>     

```
