# Migration to 8.7 kibana

**URL:** <https://discuss.elastic.co/t/migration-to-8-7-kibana/332872>\
**Category:** Kibana\
**Created:** [May 9, 2023, 6:37am UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872 "2023-05-09T06:37:28Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lilia](https://avatars.discourse-cdn.com/v4/letter/l/2bfe46/32.png) [@Lilia](https://discuss.elastic.co/u/Lilia)\
**Post date:** [May 9, 2023, 6:37am UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872/1 "2023-05-09T06:37:28Z")

</div>

Hi I'm trying to migrate custom plugin to version 8.7 of kibana, but i receive a Server error and the kibana is not loading, in the logs i have several warnings, could you please help fix it or advice how to clear the warnings?  
Warnings as follow:  
'''  
1.HealthStatus.Warning because assumedAverageRecurringRequiredThroughputPerMinutePerKibana (0) \< capacityPerMinutePerKibana (200);

'''  
2.worker stderr [BABEL] Note: The code generator has deoptimised the styling of /home/development/kibana8.7/kibana/packages/kbn-ecs/generated/ecs\_flat.ts as it exceeds the max of 500KB.

'''  
Also I receive an error  
'''  
Error: index\_not\_found\_exception.  
Root causes:index\_not\_found\_exception: no such index [.kibana], but the api is not crashing after the error in the logs I'm receiving the following warning:  
[plugins.taskManager] setting HealthStatus.Error because of expired cold timestamps

'''  
Could you please advice me how to proceed in finding what is causing the error and why?  
Many thanks in advance!

---

<div class="post-metadata">

**Author:** ![JLeysens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jleysens/32/67404_2.png) [@JLeysens](https://discuss.elastic.co/u/JLeysens)\
**Post date:** [May 9, 2023, 10:20am UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872/2 "2023-05-09T10:20:12Z")

</div>

Hello @Lilia ! From what you shared, the biggest issue to starting Kibana seems to be:

```auto
Root causes:index_not_found_exception: no such index [.kibana],

```

I am assuming you are working against a development environment. Are you able to delete all `.kibana_*` indices or just start a new cluster? This should result in Kibana creating a new consistent environment in ES to develop against.

---

<div class="post-metadata">

**Author:** ![JLeysens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jleysens/32/67404_2.png) [@JLeysens](https://discuss.elastic.co/u/JLeysens)\
**Post date:** [May 9, 2023, 1:01pm UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872/3 "2023-05-09T13:01:19Z")

</div>

I just saw there is a known issue for migrating custom plugins to 8.7 that is worth following

> <https://github.com/elastic/kibana/issues/154325>
>
> Hi!
> 
> I have maintain a external plugin.
> 
> After upgrading kibana to version \`…v8.7.0\` a plugin after build has incorect path to \`@kbn/config-schema\`.
> 
> \`var \_kbnConfigSchema = require("../../../packages/kbn-config-schema");\`
> 
> insted of: \`var \_kbnConfigSchema = require("@kbn/config-schema");\`
> 
> !\[image\](https://user-images.githubusercontent.com/173098/229764729-8b2eb20d-afd7-49d5-9ac3-b31941c4ad8a.png)
> 
> Probably it is regression after: https://github.com/elastic/kibana/pull/146212/
> 
> IMO I have configured everything correctly:
> \- tsconfig.json 
> \- kibana.json
> etc.
> 
> 
> When I run kibana in dev mode: \`yarn start --oss\` everything works ok, but problem occurs after plugin installation in desire instance.
> 
> Logs:
> 
> \`\`\`
> \[2023-04-04T10:34:17.240+00:00\]\[DEBUG\]\[elasticsearch-service\] Stopping elasticsearch service
> 
> FATAL Error: Cannot find module '../../../packages/kbn-config-schema'
> Require stack:
> \- /usr/share/kibana/plugins/plugin-name/server/config.js
> \- /usr/share/kibana/plugins/plugin-name/server/index.js
> \- /usr/share/kibana/node\_modules/@kbn/core-plugins-server-internal/src/plugin.js
> \- /usr/share/kibana/node\_modules/@kbn/core-plugins-server-internal/src/discovery/plugins\_discovery.js
> \- /usr/share/kibana/node\_modules/@kbn/core-plugins-server-internal/src/discovery/index.js
> \- /usr/share/kibana/node\_modules/@kbn/core-plugins-server-internal/src/plugins\_service.js
> \- /usr/share/kibana/node\_modules/@kbn/core-plugins-server-internal/src/index.js
> \- /usr/share/kibana/node\_modules/@kbn/core-plugins-server-internal/index.js
> \- /usr/share/kibana/node\_modules/@kbn/core-root-server-internal/src/server.js
> \- /usr/share/kibana/node\_modules/@kbn/core-root-server-internal/src/index.js
> \- /usr/share/kibana/node\_modules/@kbn/core-root-server-internal/index.js
> \- /usr/share/kibana/src/core/server/index.js
> \- /usr/share/kibana/src/cli/serve/serve.js
> \- /usr/share/kibana/src/cli/cli.js
> \- /usr/share/kibana/src/cli/dist.js
> \`\`\`
> 
> I have also tried copy plugin \`preboot\_example\` from \`examples/\` to \`plugins/\` and add \`package.json\`:
> \`\`\`
> {
> "name": "foo",
> "version": "0.0.0",
> "private": true,
> "scripts": {
> "build": "yarn plugin-helpers build",
> "plugin-helpers": "node ../../scripts/plugin\_helpers",
> "kbn": "node ../../scripts/kbn"
> }
> }
> \`\`\`
> 
> but result is the same.
> Here is plugin after build: \[prebootExample-8.7.0.zip\](https://github.com/elastic/kibana/files/11147527/prebootExample-8.7.0.zip)
> 
> Best regards,
> Mateusz

---

<div class="post-metadata">

**Author:** ![Lilia](https://avatars.discourse-cdn.com/v4/letter/l/2bfe46/32.png) [@Lilia](https://discuss.elastic.co/u/Lilia)\
**Post date:** [May 9, 2023, 2:04pm UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872/4 "2023-05-09T14:04:01Z")

</div>

Hey, thank you so much for the help. I have tried to delete all kibana indices but apparently the superuser has no privileges to send delete request. I believe i have the same problem as the mention in the issue, are you aware of any other approaches i can follow to fix it while the issue is being taken cared of elastic team?  
Thank you!

---

<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 31, 2023, 10:00pm UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872/5 "2023-05-31T22:00:55Z")

</div>

I think you may be able to use the `kibana_system` user to perform the cleanup you need.

```auto
https://kibana_system:changeme@localhost:19200
GET /

https://kibana_system:changeme@localhost:19200
GET /_cat/indices/.k*

https://kibana_system:changeme@localhost:19200
DELETE /.kibana_8.8.0_001
DELETE /.kibana_task_manager_8.8.0_001
DELETE /.kibana_ingest_8.8.0_001
DELETE /.kibana_analytics_8.8.0_001
DELETE /.kibana_security_session_1
DELETE /.kibana_security_solution_8.8.0_001
DELETE /.kibana_alerting_cases_8.8.0_001
DELETE /.kibana-event-log-8.8.0-000001

```

Yet, when working in a development environment, it is recommended to use a dev cluster that can be thrown away whenever needed, and have access to some data that can be quickly indexed for development. You can stand up a development cluster in a Kibana development environment with the `yarn es <command> [options]` command.

---

<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:** [June 28, 2023, 10:01pm UTC](https://discuss.elastic.co/t/migration-to-8-7-kibana/332872/6 "2023-06-28T22:01:21Z")

</div>

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