# Kibana upgrade failed - Error: \[config validation of \[elasticsearch\].preserveHost\]: definition for this key is missing

**URL:** https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032
**Category:** Kibana
**Created:** [June 7, 2024, 11:52am UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032 "2024-06-07T11:52:53Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![padmavathi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/padmavathi/32/134714_2.png) [@padmavathi](https://discuss.elastic.co/u/padmavathi)
#### Post date: [June 7, 2024, 11:52am UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032/1 "2024-06-07T11:52:53Z")

</div>

I have upgraded kibana from 7.17 to 8.0.1 .Im getting the below error .  
Error: [config validation of [elasticsearch].preserveHost]: definition for this key is missing

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/6/b/6b2ce14a6c9e0cbba322ee76707d1f4b33ea02b2.png)

Could you please help me ?

Thanks

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [June 7, 2024, 12:08pm UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032/2 "2024-06-07T12:08:57Z")

</div>

Please don't post images of text as they are hard to read, may not display correctly for everyone, and are not searchable.

Instead, paste the text and format it with `</>` icon or pairs of triple backticks (```), and check the preview window to make sure it's properly formatted before posting it. This makes it more likely that your question will receive a useful answer.

It would be great if you could update your post to solve this.

---

<div class="post-metadata">

### Author: ![padmavathi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/padmavathi/32/134714_2.png) [@padmavathi](https://discuss.elastic.co/u/padmavathi)
#### Post date: [June 7, 2024, 12:14pm UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032/3 "2024-06-07T12:14:50Z")

</div>

```auto
root@logsdev:/etc/kibana# /usr/share/kibana/bin/kibana --allow-root
[2024-06-07T13:06:18.026+01:00][INFO][plugins-service] Plugin "metricsEntities" is disabled.
[2024-06-07T13:06:18.079+01:00][FATAL][root] Error: [config validation of [elasticsearch].preserveHost]: definition for this key is missing
    at ensureValidConfiguration (/usr/share/kibana/src/core/server/config/ensure_valid_configuration.js:25:11)
    at Server.preboot (/usr/share/kibana/src/core/server/server.js:160:5)
    at Root.preboot (/usr/share/kibana/src/core/server/root/index.js:48:14)
    at bootstrap (/usr/share/kibana/src/core/server/bootstrap.js:99:9)
    at Command.<anonymous> (/usr/share/kibana/src/cli/serve/serve.js:216:5)

 FATAL Error: [config validation of [elasticsearch].preserveHost]: definition for this key is missing

```

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [June 7, 2024, 1:21pm UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032/4 "2024-06-07T13:21:21Z")

</div>

Look at [Kibana 8.0.0-beta1 | Kibana Guide [8.14] | Elastic](https://www.elastic.co/guide/en/kibana/8.14/release-notes-8.0.0-beta1.html)

> Some of the `so/server/es` settings have been removed. If your configuration uses the following settings, Kibana fails to start:
> 
> - `savedObjects.indexCheckTimeout`
> - `server.xsrf.token`
> - `elasticsearch.preserveHost`
> - `elasticsearch.startupTimeout`

Some comments:

- Don't use a 8.0 version of the stack. We now have 8.13.4.
- You should have used the [upgrade assistant](https://www.elastic.co/guide/en/kibana/current/upgrade-assistant.html) before upgrading. Did you?

This guide explains how to upgrade: [Upgrade Kibana | Kibana Guide [8.14] | Elastic](https://www.elastic.co/guide/en/kibana/current/upgrade.html)

---

<div class="post-metadata">

### Author: ![padmavathi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/padmavathi/32/134714_2.png) [@padmavathi](https://discuss.elastic.co/u/padmavathi)
#### Post date: [June 13, 2024, 10:46am UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032/5 "2024-06-13T10:46:21Z")

</div>

yes i have used upgrade assistant and upgraded elasticsearch v.8.0.1 successfully .

Is there any issue with kibana 8.0.1?

Could you please check the below logging format :

logging.root.level: debug

logging:  
appenders:  
file:  
type: file  
fileName: /var/log/kibana/kibana.log  
layout:  
type: pattern  
root:  
appenders:  
- default  
- file

I am getting the error while using the layout type as pattern.

Could you please advise on this?

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [June 13, 2024, 12:21pm UTC](https://discuss.elastic.co/t/kibana-upgrade-failed-error-config-validation-of-elasticsearch-preservehost-definition-for-this-key-is-missing/361032/6 "2024-06-13T12:21:05Z")

</div>

> [@padmavathi](#):
>
> Is there any issue with kibana 8.0.1?

Yes. And we are now on 8.14.1. So lot of things have been fixed since then.

> [@padmavathi](#):
>
> Could you please advise on this?

I think it's another question and that the original one is solved, right?  
If so, please open a new discussion and share what you did exactly, what are the logs... And please [read this](https://discuss.elastic.co/t/about-the-elasticsearch-category/21) about how to format.
