# Report from Kibana connected to Elastic Cloud - Failed to decrypt report job data

**URL:** <https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026>\
**Category:** Kibana\
**Created:** [May 3, 2021, 9:32pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026 "2021-05-03T21:32:29Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![dimitris\_sb](https://avatars.discourse-cdn.com/v4/letter/d/eada6e/32.png) [@dimitris\_sb](https://discuss.elastic.co/u/dimitris_sb)\
**Post date:** [May 3, 2021, 9:32pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/1 "2021-05-03T21:32:29Z")

</div>

Hi All,

I noticed the following error on a custom Kibana which is connected to Elastic Cloud elasticsearch instance. Reverse proxy exposes port 80 and then Cloudflare provides https connection.  
Therefore, I have set

```
## Reporting

```

xpack.reporting.enabled: true  
xpack.reporting.encryptionKey: "32 characters"  
xpack.reporting.kibanaServer.hostname: "0.0.0.0"  
xpack.reporting.kibanaServer.port: 80  
xpack.reporting.kibanaServer.protocol: "http"

I often (7 out of 8 times) get the following error:

> The reporting job failed  
> Error: Failed to decrypt report job data. Please ensure that xpack.reporting.encryptionKey is set and re-generate this report. Error: Unsupported state or unable to authenticate data

and the sometimes PDF report succeeds...

In Kibana, the following error is also logged on failures:  
`"tags":["warning","plugins","reporting","esqueue","queue-worker"],"pid":58498,"message":"ko12345h194y39e9ab7bnm8a - _claimPendingJobs encountered a version conflict on updating pending job ko12yvo4194y39e9ab2a2rav: Error: [version_conflict_engine_exception] [ko12yvo4194y39e9ab2a2rav]: version conflict, required seqNo [63], primary term [1]. current document has seqNo [65] and primary term [1],`

Any ideas?

---

<div class="post-metadata">

**Author:** ![rashmi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rashmi/32/16391_2.png) [@rashmi](https://discuss.elastic.co/u/rashmi)\
**Post date:** [May 3, 2021, 9:39pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/2 "2021-05-03T21:39:24Z")

</div>

> [@dimitris\_sb](#):
>
> The reporting job failed  
> Error: Failed to decrypt report job data.

If this error is intermittent then you might be running into a problem in which the amount of data used to generate the report is too large. Here's a [similar issue](https://discuss.elastic.co/t/error-in-reporting/147595) in which the user solved the problem by using a smaller time interval. Can you see if this works, to confirm that this is the problem?

Thanks  
Rashmi

---

<div class="post-metadata">

**Author:** ![dimitris\_sb](https://avatars.discourse-cdn.com/v4/letter/d/eada6e/32.png) [@dimitris\_sb](https://discuss.elastic.co/u/dimitris_sb)\
**Post date:** [May 3, 2021, 9:42pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/3 "2021-05-03T21:42:33Z")

</div>

Thank you for your prompt answer.  
I do not think that the timeout is the problem as I have already set:

```
elasticsearch.requestTimeout: 120000
elasticsearch.shardTimeout: 120000

```

I believe that there is a conflict with the reverse proxy or the encryptionKey which is different from the one Elastic Cloud provides with its own Kibana ...

The error from Kibana is not very helpful and I do not understand why I have 2 successful tries and then I get failures with the same error ...

---

<div class="post-metadata">

**Author:** ![rashmi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rashmi/32/16391_2.png) [@rashmi](https://discuss.elastic.co/u/rashmi)\
**Post date:** [May 3, 2021, 9:43pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/4 "2021-05-03T21:43:57Z")

</div>

@tsullivan any advice here?

Thanks  
Rashmi

---

<div class="post-metadata">

**Author:** ![tsullivan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsullivan/32/31077_2.png) [@tsullivan](https://discuss.elastic.co/u/tsullivan)\
**Post date:** [May 3, 2021, 10:33pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/5 "2021-05-03T22:33:44Z")

</div>

> [@dimitris\_sb](#):
>
> I believe that there is a conflict with the reverse proxy or the encryptionKey which is different from the one Elastic Cloud provides with its own Kibana ...

Kibana instances work in a pool to run reports, so that a single instance of Kibana doesn't end up being responsible for serving interactive users and also executing reports async. Because jobs can be claimed by other instances, the encryption key must be set to the same value for all the Kibana instances that are connected to the cluster.

I recommend either setting the encryption key for the cloud instance to be the same and allow that instance to run report jobs, or disable that instance from being able to claim jobs by setting `xpack.reporting.queue.pollEnabled: false` .

---

<div class="post-metadata">

**Author:** ![dimitris\_sb](https://avatars.discourse-cdn.com/v4/letter/d/eada6e/32.png) [@dimitris\_sb](https://discuss.elastic.co/u/dimitris_sb)\
**Post date:** [May 3, 2021, 10:39pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/6 "2021-05-03T22:39:02Z")

</div>

Thank you @tsullivan for your suggestion, I had just changed the setting to Elastic Cloud's configuration (just the xpack.reporting.encryptionKey) and instantly noticed that I have no fails from my self-hosted Kibana. I think that I will follow your advice and I will set xpack.reporting.queue.pollEnabled to false instead.

Thank you again!

---

<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:** [May 31, 2021, 10:39pm UTC](https://discuss.elastic.co/t/report-from-kibana-connected-to-elastic-cloud-failed-to-decrypt-report-job-data/272026/7 "2021-05-31T22:39:40Z")

</div>

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