Skip to content

Commit f07aed1

Browse files
authored
[8.15] Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257) (elastic#208757)
# Backport This will backport the following commits from `main` to `8.15`: - [Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257)](elastic#208257) <!--- Backport version: 9.6.4 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Tim Sullivan","email":"[email protected]"},"sourceCommit":{"committedDate":"2025-01-29T10:54:09Z","message":"Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257)\n\n## Summary\r\n\r\nCloses https://github.com/elastic/kibana/issues/201281\r\nCloses https://github.com/elastic/kibana/issues/200653\r\n\r\n---------\r\n\r\nCo-authored-by: wajihaparvez <[email protected]>","sha":"5f59395f185c855be3dff477e8f66d328e0b8073","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","docs","v8.15.0","v8.16.0","backport:version","v8.17.0","v8.18.0","v8.16.4","v8.17.2"],"title":"Update Reporting documentation: ES configuration, avoiding Token expiration","number":208257,"url":"https://github.com/elastic/kibana/pull/208257","mergeCommit":{"message":"Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257)\n\n## Summary\r\n\r\nCloses https://github.com/elastic/kibana/issues/201281\r\nCloses https://github.com/elastic/kibana/issues/200653\r\n\r\n---------\r\n\r\nCo-authored-by: wajihaparvez <[email protected]>","sha":"5f59395f185c855be3dff477e8f66d328e0b8073"}},"sourceBranch":"main","suggestedTargetBranches":["8.15"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/208257","number":208257,"mergeCommit":{"message":"Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257)\n\n## Summary\r\n\r\nCloses https://github.com/elastic/kibana/issues/201281\r\nCloses https://github.com/elastic/kibana/issues/200653\r\n\r\n---------\r\n\r\nCo-authored-by: wajihaparvez <[email protected]>","sha":"5f59395f185c855be3dff477e8f66d328e0b8073"}},{"branch":"8.15","label":"v8.15.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/208714","number":208714,"state":"MERGED","mergeCommit":{"sha":"a261ca1b09337c30d207a403978d759a2a14f8c1","message":"[8.16] Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257) (elastic#208714)\n\n# Backport\n\nThis will backport the following commits from `main` to `8.16`:\n- [Update Reporting documentation: ES configuration, avoiding Token\nexpiration (elastic#208257)](https://github.com/elastic/kibana/pull/208257)\n\n<!--- Backport version: 9.4.3 -->\n\n### Questions ?\nPlease refer to the [Backport tool\ndocumentation](https://github.com/sqren/backport)\n\n<!--BACKPORT [{\"author\":{\"name\":\"Tim\nSullivan\",\"email\":\"[email protected]\"},\"sourceCommit\":{\"committedDate\":\"2025-01-29T10:54:09Z\",\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\",\"branchLabelMapping\":{\"^v9.0.0$\":\"main\",\"^v8.18.0$\":\"8.x\",\"^v(\\\\d+).(\\\\d+).\\\\d+$\":\"$1.$2\"}},\"sourcePullRequest\":{\"labels\":[\"release_note:skip\",\"v9.0.0\",\"docs\",\"v8.15.0\",\"v8.16.0\",\"backport:version\",\"v8.17.0\",\"v8.18.0\"],\"title\":\"Update\nReporting documentation: ES configuration, avoiding Token\nexpiration\",\"number\":208257,\"url\":\"https://github.com/elastic/kibana/pull/208257\",\"mergeCommit\":{\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\"}},\"sourceBranch\":\"main\",\"suggestedTargetBranches\":[\"8.15\",\"8.16\",\"8.17\",\"8.x\"],\"targetPullRequestStates\":[{\"branch\":\"main\",\"label\":\"v9.0.0\",\"branchLabelMappingKey\":\"^v9.0.0$\",\"isSourceBranch\":true,\"state\":\"MERGED\",\"url\":\"https://github.com/elastic/kibana/pull/208257\",\"number\":208257,\"mergeCommit\":{\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\"}},{\"branch\":\"8.15\",\"label\":\"v8.15.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.16\",\"label\":\"v8.16.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.17\",\"label\":\"v8.17.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.x\",\"label\":\"v8.18.0\",\"branchLabelMappingKey\":\"^v8.18.0$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"}]}]\nBACKPORT-->\n\nCo-authored-by: Tim Sullivan <[email protected]>"}},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/208716","number":208716,"state":"MERGED","mergeCommit":{"sha":"b5778932f5f1e2392660305200b49607e3034855","message":"[8.17] Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257) (elastic#208716)\n\n# Backport\n\nThis will backport the following commits from `main` to `8.17`:\n- [Update Reporting documentation: ES configuration, avoiding Token\nexpiration (elastic#208257)](https://github.com/elastic/kibana/pull/208257)\n\n<!--- Backport version: 9.4.3 -->\n\n### Questions ?\nPlease refer to the [Backport tool\ndocumentation](https://github.com/sqren/backport)\n\n<!--BACKPORT [{\"author\":{\"name\":\"Tim\nSullivan\",\"email\":\"[email protected]\"},\"sourceCommit\":{\"committedDate\":\"2025-01-29T10:54:09Z\",\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\",\"branchLabelMapping\":{\"^v9.0.0$\":\"main\",\"^v8.18.0$\":\"8.x\",\"^v(\\\\d+).(\\\\d+).\\\\d+$\":\"$1.$2\"}},\"sourcePullRequest\":{\"labels\":[\"release_note:skip\",\"v9.0.0\",\"docs\",\"v8.15.0\",\"v8.16.0\",\"backport:version\",\"v8.17.0\",\"v8.18.0\"],\"title\":\"Update\nReporting documentation: ES configuration, avoiding Token\nexpiration\",\"number\":208257,\"url\":\"https://github.com/elastic/kibana/pull/208257\",\"mergeCommit\":{\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\"}},\"sourceBranch\":\"main\",\"suggestedTargetBranches\":[\"8.15\",\"8.16\",\"8.17\",\"8.x\"],\"targetPullRequestStates\":[{\"branch\":\"main\",\"label\":\"v9.0.0\",\"branchLabelMappingKey\":\"^v9.0.0$\",\"isSourceBranch\":true,\"state\":\"MERGED\",\"url\":\"https://github.com/elastic/kibana/pull/208257\",\"number\":208257,\"mergeCommit\":{\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\"}},{\"branch\":\"8.15\",\"label\":\"v8.15.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.16\",\"label\":\"v8.16.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.17\",\"label\":\"v8.17.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.x\",\"label\":\"v8.18.0\",\"branchLabelMappingKey\":\"^v8.18.0$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"}]}]\nBACKPORT-->\n\nCo-authored-by: Tim Sullivan <[email protected]>"}},{"branch":"8.x","label":"v8.18.0","branchLabelMappingKey":"^v8.18.0$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/208717","number":208717,"state":"MERGED","mergeCommit":{"sha":"8037864bc484c6e79952e590f37f44e27eef9f3a","message":"[8.x] Update Reporting documentation: ES configuration, avoiding Token expiration (elastic#208257) (elastic#208717)\n\n# Backport\n\nThis will backport the following commits from `main` to `8.x`:\n- [Update Reporting documentation: ES configuration, avoiding Token\nexpiration (elastic#208257)](https://github.com/elastic/kibana/pull/208257)\n\n<!--- Backport version: 9.4.3 -->\n\n### Questions ?\nPlease refer to the [Backport tool\ndocumentation](https://github.com/sqren/backport)\n\n<!--BACKPORT [{\"author\":{\"name\":\"Tim\nSullivan\",\"email\":\"[email protected]\"},\"sourceCommit\":{\"committedDate\":\"2025-01-29T10:54:09Z\",\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\",\"branchLabelMapping\":{\"^v9.0.0$\":\"main\",\"^v8.18.0$\":\"8.x\",\"^v(\\\\d+).(\\\\d+).\\\\d+$\":\"$1.$2\"}},\"sourcePullRequest\":{\"labels\":[\"release_note:skip\",\"v9.0.0\",\"docs\",\"v8.15.0\",\"v8.16.0\",\"backport:version\",\"v8.17.0\",\"v8.18.0\"],\"title\":\"Update\nReporting documentation: ES configuration, avoiding Token\nexpiration\",\"number\":208257,\"url\":\"https://github.com/elastic/kibana/pull/208257\",\"mergeCommit\":{\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\"}},\"sourceBranch\":\"main\",\"suggestedTargetBranches\":[\"8.15\",\"8.16\",\"8.17\",\"8.x\"],\"targetPullRequestStates\":[{\"branch\":\"main\",\"label\":\"v9.0.0\",\"branchLabelMappingKey\":\"^v9.0.0$\",\"isSourceBranch\":true,\"state\":\"MERGED\",\"url\":\"https://github.com/elastic/kibana/pull/208257\",\"number\":208257,\"mergeCommit\":{\"message\":\"Update\nReporting documentation: ES configuration, avoiding Token expiration\n(elastic#208257)\\n\\n## Summary\\r\\n\\r\\nCloses\nhttps://github.com/elastic/issues/201281\\r\\nCloses\nhttps://github.com/elastic/issues/200653\\r\\n\\r\\n---------\\r\\n\\r\\nCo-authored-by:\nwajihaparvez\n<[email protected]>\",\"sha\":\"5f59395f185c855be3dff477e8f66d328e0b8073\"}},{\"branch\":\"8.15\",\"label\":\"v8.15.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.16\",\"label\":\"v8.16.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.17\",\"label\":\"v8.17.0\",\"branchLabelMappingKey\":\"^v(\\\\d+).(\\\\d+).\\\\d+$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"},{\"branch\":\"8.x\",\"label\":\"v8.18.0\",\"branchLabelMappingKey\":\"^v8.18.0$\",\"isSourceBranch\":false,\"state\":\"NOT_CREATED\"}]}]\nBACKPORT-->\n\nCo-authored-by: Tim Sullivan <[email protected]>"}}]}] BACKPORT-->
1 parent f6a667e commit f07aed1

File tree

2 files changed

+23
-2
lines changed

2 files changed

+23
-2
lines changed

docs/setup/configuring-reporting.asciidoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ to enable the {kib} server to have screenshotting capabilities.
1717
* <<securing-reporting>>
1818
* <<install-reporting-packages>>
1919
* <<set-reporting-server-host>>
20+
* <<reporting-elasticsearch-configuration>>
2021

2122
[float]
2223
[[grant-user-access]]
@@ -246,3 +247,10 @@ address.
246247

247248
For the most reliable configuration of PDF/PNG {report-features}, consider installing {kib} using <<docker, Docker>>, or
248249
using <<set-up-on-cloud, Elastic Cloud>>.
250+
251+
[float]
252+
[[reporting-elasticsearch-configuration]]
253+
=== Ensure {es} allows built-in templates
254+
Reporting relies on {es} to install a mapping template for the data stream that stores reports. Ensure that {es} allows built-in
255+
templates to be installed by keeping the `stack.templates.enabled` setting at the default value of `true`. For more information, see
256+
{ref}/index-management-settings.html#stack-templates-enabled[Index management settings].

docs/user/reporting/reporting-csv-troubleshooting.asciidoc

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,5 +88,18 @@ image::https://images.contentstack.io/v3/assets/bltefdd0b53724fa2ce/blt4758e67aa
8888
[[reporting-troubleshooting-csv-token-expired]]
8989
=== Token expiration
9090

91-
To avoid token expirations, use a type of authentication that doesn't expire (such as Basic auth) or run the export using scripts that query Elasticsearch directly.
92-
In a custom script, you have the ability to refresh the auth token as needed, such as once before each query.
91+
A relatively common type of error seen for CSV exports is: `security_exception Root causes: security_exception: token expired`.
92+
93+
This error occurs in deployments that use token-based authentication (SAML tokens) when it takes too long to create the CSV report with the authentication cached in report job details.
94+
95+
This means that the deployment is stable, but the size of the requested report is too large to complete within the time allowed by the authentication token available to the Reporting task.
96+
97+
[float]
98+
[[avoid-token-expiration]]
99+
==== Avoiding token expiration
100+
101+
You can use the following workarounds for this error:
102+
103+
* Create smaller reports. Instead of creating one report that covers a large time range, create multiple reports that cover segmented time ranges.
104+
* Increase `xpack.security.authc.token.timeout`, which is set to `20m` by default.
105+
* To avoid token expirations completely, use a type of authentication that doesn't expire (such as Basic auth), or run the export using scripts that query {es} directly.

0 commit comments

Comments
 (0)