# The parent task was cancelled, shouldn't start any child tasks

**URL:** <https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686>\
**Category:** Elasticsearch\
**Created:** [January 20, 2021, 5:24pm UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686 "2021-01-20T17:24:58Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aniket\_Pant](https://avatars.discourse-cdn.com/v4/letter/a/77aa72/32.png) [@Aniket\_Pant](https://discuss.elastic.co/u/Aniket_Pant)\
**Post date:** [January 20, 2021, 5:24pm UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/1 "2021-01-20T17:24:58Z")

</div>

- Total shards 110
- Data 3.7gb
- Indices 99

Problem in kibana monitoring section.The page was showing indices fails.

In elasticsearch log file

```auto
[2021-01-20T21:27:16,584][INFO][o.e.m.j.JvmGcMonitorService] [elastic] [gc][3089] overhead, spent [254ms] collecting in the last [1s]
[2021-01-20T21:28:28,896][ERROR][o.e.b.ElasticsearchUncaughtExceptionHandler] [elastic] uncaught exception in thread [elasticsearch[elastic][search][T#3]]
org.elasticsearch.tasks.TaskCancelledException: The parent task was cancelled, shouldn't start any child tasks
[2021-01-20T21:56:23,133][WARN][r.suppressed] [elastic] path: /elastalert_status/_search, params: {index=elastalert_status}
org.elasticsearch.action.search.SearchPhaseExecutionException: all shards failed
[2021-01-20T22:01:58,438][INFO][o.e.m.j.JvmGcMonitorService] [elastic] [gc][5151] overhead, spent [336ms] collecting in the last [1.2s]

```

The jvm heap consumed in that time was 1.6gb out of 2.6gb. I am using elk 7.10 and i am monitoring elk with metricbeat.

---

<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:** [January 20, 2021, 5:40pm UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/2 "2021-01-20T17:40:34Z")

</div>

Logging this message as an `ERROR` is a bug, this exception is expected when a search is cancelled. I opened an issue to report it:

> <https://github.com/elastic/elasticsearch/issues/67784>
>
> When a task is cancelled it cannot create any more child tasks, which means that it cannot execute any further transport...

---

<div class="post-metadata">

**Author:** ![Aniket\_Pant](https://avatars.discourse-cdn.com/v4/letter/a/77aa72/32.png) [@Aniket\_Pant](https://discuss.elastic.co/u/Aniket_Pant)\
**Post date:** [January 20, 2021, 6:20pm UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/3 "2021-01-20T18:20:54Z")

</div>

Do i need to update elk

---

<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:** [January 20, 2021, 7:36pm UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/4 "2021-01-20T19:36:04Z")

</div>

Yes upgrading to 7.10.2 will stop that message from being logged.

---

<div class="post-metadata">

**Author:** ![Aniket\_Pant](https://avatars.discourse-cdn.com/v4/letter/a/77aa72/32.png) [@Aniket\_Pant](https://discuss.elastic.co/u/Aniket_Pant)\
**Post date:** [January 21, 2021, 5:17am UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/5 "2021-01-21T05:17:57Z")

</div>

i upgraded elk to 7.10.2 version but the problem is not solved

---

<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:** [January 21, 2021, 7:08am UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/6 "2021-01-21T07:08:49Z")

</div>

I expect the logs look different now, probably worth sharing a fresh copy.

---

<div class="post-metadata">

**Author:** ![sreekanth](https://avatars.discourse-cdn.com/v4/letter/s/e47774/32.png) [@sreekanth](https://discuss.elastic.co/u/sreekanth)\
**Post date:** [January 22, 2021, 10:46am UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/7 "2021-01-22T10:46:07Z")

</div>

I am also facing similar issue for search.  
ES version: 7.8.1

**Exception:**  
` org.elasticsearch.action.search.SearchPhaseExecutionException: all shards failed	at org.elasticsearch.action.search.AbstractSearchAsyncAction.onPhaseFailure(AbstractSearchAsyncAction.java:551) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.AbstractSearchAsyncAction.executeNextPhase(AbstractSearchAsyncAction.java:309) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.FetchSearchPhase.moveToNextPhase(FetchSearchPhase.java:231) [elasticsearch-7.8.1.jar:7.8.1] at org.elasticsearch.action.search.FetchSearchPhase.lambda$innerRun$1(FetchSearchPhase.java:119) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.CountedCollector.countDown(CountedCollector.java:53) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.FetchSearchPhase.innerRun(FetchSearchPhase.java:155) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.FetchSearchPhase.access$000(FetchSearchPhase.java:47) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.FetchSearchPhase$1.doRun(FetchSearchPhase.java:95) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:44) [elasticsearch-7.8.1.jar:7.8.1] at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:695) [elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-7.8.1.jar:7.8.1]	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]	at java.lang.Thread.run(Thread.java:834) [?:?]Caused by: org.elasticsearch.tasks.TaskCancelledException: The parent task was cancelled, shouldn't start any child tasks at org.elasticsearch.tasks.TaskManager$CancellableTaskHolder.registerChildNode(TaskManager.java:521) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.tasks.TaskManager.registerChildNode(TaskManager.java:201) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.transport.TransportService.sendRequest(TransportService.java:627) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.transport.TransportService.sendChildRequest(TransportService.java:704) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.transport.TransportService.sendChildRequest(TransportService.java:696) ~[elasticsearch-7.8.1.jar:7.8.1] at org.elasticsearch.action.search.SearchTransportService.sendExecuteFetch(SearchTransportService.java:173) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.SearchTransportService.sendExecuteFetch(SearchTransportService.java:163) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.FetchSearchPhase.executeFetch(FetchSearchPhase.java:180) ~[elasticsearch-7.8.1.jar:7.8.1]	at org.elasticsearch.action.search.FetchSearchPhase.innerRun(FetchSearchPhase.java:162) ~[elasticsearch-7.8.1.jar:7.8.1]	... 9 more`

---

<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:** [February 19, 2021, 10:46am UTC](https://discuss.elastic.co/t/the-parent-task-was-cancelled-shouldnt-start-any-child-tasks/261686/8 "2021-02-19T10:46:19Z")

</div>

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