# Long optimization of kibana during start up on kubernetes/openshift

**URL:** https://forum.search-guard.com/t/long-optimization-of-kibana-during-start-up-on-kubernetes-openshift/1933
**Category:** Search Guard
**Created:** [August 20, 2020, 8:37am UTC](https://forum.search-guard.com/t/long-optimization-of-kibana-during-start-up-on-kubernetes-openshift/1933 "2020-08-20T08:37:30Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Kosmonafft](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.search-guard.com/kosmonafft/32/1010_2.png) [@Kosmonafft](https://forum.search-guard.com/u/Kosmonafft)
#### Post date: [August 20, 2020, 8:37am UTC](https://forum.search-guard.com/t/long-optimization-of-kibana-during-start-up-on-kubernetes-openshift/1933/1 "2020-08-20T08:37:31Z")

</div>

Hi,

how do you deal with the extremely long optimization time of kibana during the deployments on kubernetes or (in my case) openshift?

From this documentation I learned that this is a well known issue: [Kibana Troubleshooting | Security for Elasticsearch | Search Guard](https://docs.search-guard.com/latest/troubleshooting-kibana). But as for me I am not able to increase the memeory to 8 GB since I have limited quotas.

Regarding the second suggestion of using `"--no-optimize"` flag: Do you know how it influence kibana? And where would you pass this argument in your Dockerfile? To the kibana executable?

THanks

---

<div class="post-metadata">

### Author: ![srgbnd](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.search-guard.com/srgbnd/32/506_2.png) [@srgbnd](https://forum.search-guard.com/u/srgbnd)
#### Post date: [August 27, 2020, 1:38pm UTC](https://forum.search-guard.com/t/long-optimization-of-kibana-during-start-up-on-kubernetes-openshift/1933/2 "2020-08-27T13:38:47Z")

</div>

Yes, this is a well-known Kibana issue which exists since v6 [Installing kibana plugin fails due to node running out of heap memory · Issue #25849 · elastic/kibana · GitHub](https://github.com/elastic/kibana/issues/25849)

If you can’t increase the size of the NodeJS heap, unpack SG and move it manually into the `kibana/plugins` folder. This way, Kibana does optimization while starting.

For example

```bash
wget https://maven.search-guard.com/search-guard-kibana-plugin-release/com/floragunn/search-guard-kibana-plugin/7.8.1-43.0.0/search-guard-kibana-plugin-7.8.1-43.0.0.zip
unzip search-guard-kibana-plugin-7.8.1-43.0.0.zip 
mv kibana/searchguard-kibana-7.8.1-43.0.0 /path/to/kibana/plugins/searchguard

```

---

<div class="post-metadata">

### Author: ![system](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.search-guard.com/system/32/1870_2.png) [@system](https://forum.search-guard.com/u/system)
#### Post date: [September 17, 2020, 1:38pm UTC](https://forum.search-guard.com/t/long-optimization-of-kibana-during-start-up-on-kubernetes-openshift/1933/3 "2020-09-17T13:38:48Z")

</div>

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