# Signals to consider the nature of operation

**URL:** https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681
**Category:** Elasticsearch
**Created:** [September 23, 2023, 10:31pm UTC](https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681 "2023-09-23T22:31:12Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Dhineshkumar\_R](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dhineshkumar_r/32/122038_2.png) [@Dhineshkumar\_R](https://discuss.elastic.co/u/Dhineshkumar_R)
#### Post date: [September 23, 2023, 10:31pm UTC](https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681/1 "2023-09-23T22:31:12Z")

</div>

Hello folks,

I recently came across this post [Elasticsearch memory-bound tasks](https://discuss.elastic.co/t/elasticsearch-memory-bound-tasks/213781/2). Basis which I am trying to understand the nature of a search request to my cluster.

Following are some questions I have

1. What are the signals I should look at to determine if my search request is I/O bound, CPU bound?
2. I am aware of the explain and profile API for search request. But I'm not sure which fields will help me determine the nature of my search request. Any pointer on the fields/API that I should pay attention to would be really helpful.

Thanks much. Please let me know if you need more info. from my side.

---

<div class="post-metadata">

### Author: ![Dhineshkumar\_R](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dhineshkumar_r/32/122038_2.png) [@Dhineshkumar\_R](https://discuss.elastic.co/u/Dhineshkumar_R)
#### Post date: [September 28, 2023, 6:51am UTC](https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681/2 "2023-09-28T06:51:36Z")

</div>

If anyone has looked into such details of search query, please share your insights.

---

<div class="post-metadata">

### Author: ![Dhineshkumar\_R](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dhineshkumar_r/32/122038_2.png) [@Dhineshkumar\_R](https://discuss.elastic.co/u/Dhineshkumar_R)
#### Post date: [October 16, 2023, 4:03am UTC](https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681/3 "2023-10-16T04:03:20Z")

</div>

Assuming there are no APIs that'd give me a breakdown of time spent on different stages of search, if I observe the field `query_time_in_millis` in node stats to be significantly higher than `fetch_time_in_millis`, is it fair to say my search requests are more CPU bound than disk bound?

---

<div class="post-metadata">

### Author: ![Sunile\_Manjee](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sunile_manjee/32/111461_2.png) [@Sunile\_Manjee](https://discuss.elastic.co/u/Sunile_Manjee)
#### Post date: [October 17, 2023, 3:11am UTC](https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681/4 "2023-10-17T03:11:36Z")

</div>

> [@Dhineshkumar\_R](#):
>
> Following are some questions I have
> 
> 1. What are the signals I should look at to determine if my search request is I/O bound, CPU bound?
> 2. I am aware of the explain and profile API for search request. But I'm not sure which fields will help me determine the nature of my search request. Any pointer on the fields/API that I should pay attention to would be really helpful.

many ways to debug where your queries may be spending most of their time.

`GET /_nodes/hot_threads` - This API provides a snapshot of the busiest threads in the system. If your query is causing a lot of CPU usage, these threads can give you a hint.

Slow logs - [Slow Log | Elasticsearch Guide [8.11] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/index-modules-slowlog.html)

`GET /_nodes/stats/fs` - Check for `io_stats` in the response which will give you information about disk operations.

`GET /\_nodes/stats/os' - Look for the os.cpu.percent metric in the response.

use devtool query profiler or `GET /index_name/_search?explain=true` - While this doesn't directly tell you if a query is CPU or disk bound, the \_explain endpoint provides detailed information about how a query is executed.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [November 14, 2023, 3:12am UTC](https://discuss.elastic.co/t/signals-to-consider-the-nature-of-operation/343681/5 "2023-11-14T03:12:00Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
