# Which loggers does Elasticsearch have?

**URL:** <https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514>\
**Category:** Elasticsearch\
**Created:** [March 6, 2025, 11:08am UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514 "2025-03-06T11:08:30Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ACoder](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/acoder/32/113449_2.png) [@ACoder](https://discuss.elastic.co/u/ACoder)\
**Post date:** [March 6, 2025, 11:08am UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/1 "2025-03-06T11:08:30Z")

</div>

The [doc](https://www.elastic.co/guide/en/elasticsearch/reference/current/logging.html) says:

> Messages are logged by a hierarchy of loggers which matches the hierarchy of Java packages and classes in the [Elasticsearch source code](https://github.com/elastic/elasticsearch/).

And it gives an example:

```auto
logger.org.elasticsearch.discovery: DEBUG

```

Is there a list of all available loggers? Can I set the level of all of them, instead one line for each?

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [March 6, 2025, 12:18pm UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/2 "2025-03-06T12:18:06Z")

</div>

Also from the same docs:

> By default Elasticsearch includes all messages at levels `INFO` , `WARN` , `ERROR` and `FATAL` in its logs, but filters out messages at levels `DEBUG` and `TRACE` . This is the recommended configuration. Do not filter out messages at `INFO` or higher log levels or else you may not be able to understand your cluster’s behaviour or troubleshoot common problems. Do not enable logging at levels `DEBUG` or `TRACE` unless you are following instructions elsewhere in this manual which call for more detailed logging, or you are an expert user who will be reading the Elasticsearch source code to determine the meaning of the logs.

So technically (if somewhat unhelpfully) the answer is yes, there is a list of loggers: the source code. If you're not ok with reading the source code, it probably won't be very useful to adjust any loggers other than the ones mentioned in the manual.

Maybe let's turn this around: are you trying to troubleshoot something but struggling because of insufficient detail in the logs? If so, that might be a bug. Can we help you with the troubleshooting here so we can understand what we can do to improve the default logs to the point where you don't feel the need to adjust anything?

---

<div class="post-metadata">

**Author:** ![ACoder](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/acoder/32/113449_2.png) [@ACoder](https://discuss.elastic.co/u/ACoder)\
**Post date:** [March 6, 2025, 12:59pm UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/3 "2025-03-06T12:59:23Z")

</div>

I posted this post because of two reasons:

1. I'm curious how many loggers Elasticsearch can have.
2. I do want to decrease the overall log level to WARN to filter out some unnecessary info, although the doc says one should keep it to INFO.

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [March 6, 2025, 1:07pm UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/4 "2025-03-06T13:07:30Z")

</div>

> [@ACoder](#):
>
> - I'm curious how many loggers Elasticsearch can have.

In `main`, a rough approximation would be about 1500.

```auto
$ git grep 'LogManager.getLogger' | wc -l
    1521

```

> [@ACoder](#):
>
> I do want to decrease the overall log level to WARN to filter out some unnecessary info

It's ultimately up to you, but we do recommend not doing this. How would a list of all the loggers help with this?

---

<div class="post-metadata">

**Author:** ![ACoder](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/acoder/32/113449_2.png) [@ACoder](https://discuss.elastic.co/u/ACoder)\
**Post date:** [March 6, 2025, 3:27pm UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/5 "2025-03-06T15:27:53Z")

</div>

> [@DavidTurner](#):
>
> How would a list of all the loggers help with this?

I was curious when I read the doc, so I wanted to know how many loggers Elasticsearch has. It has nothing to do with `decrease the overall log level to WARN`. For that, is it possible to write only one line in `elasticsearch.yml`?

ChatGPT says:

```auto
# Set the logging level for all Elasticsearch loggers to WARN  
logger.org.elasticsearch.level = WARN

```

But I haven't found this mentioned in doc.

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [March 6, 2025, 3:42pm UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/6 "2025-03-06T15:42:56Z")

</div>

> [@ACoder](#):
>
> But I haven't found this mentioned in doc.

Well yeah that's because ChatGPT's claim is not true.

Pretty much all of the loggers in Elasticsearch are under `org.elasticsearch` so you can set that logger to `WARN` using the methods described in the manual.

---

<div class="post-metadata">

**Author:** ![ACoder](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/acoder/32/113449_2.png) [@ACoder](https://discuss.elastic.co/u/ACoder)\
**Post date:** [March 6, 2025, 3:54pm UTC](https://discuss.elastic.co/t/which-loggers-does-elasticsearch-have/375514/7 "2025-03-06T15:54:51Z")

</div>

> [@DavidTurner](#):
>
> using the methods described in the manual

Thank you. But I still think it's strange that there is no way to modify the log level of all 1500+ loggers in one line...
