# this.uiSettings is undefined

**URL:** <https://discuss.elastic.co/t/this-uisettings-is-undefined/251689>\
**Category:** Kibana\
**Created:** [October 11, 2020, 8:14pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689 "2020-10-11T20:14:49Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kenneth\_M\_Kolano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kenneth_m_kolano/32/38752_2.png) [@Kenneth\_M\_Kolano](https://discuss.elastic.co/u/Kenneth_M_Kolano)\
**Post date:** [October 11, 2020, 8:14pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/1 "2020-10-11T20:14:50Z")

</div>

After updating to a recent release of ELK and importing my old discover pane and visualizations, besides one using Timelion, all fail to display showing only the error...  
"this.uiSettings is undefined"?

---

<div class="post-metadata">

**Author:** ![nickpeihl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nickpeihl/32/112622_2.png) [@nickpeihl](https://discuss.elastic.co/u/nickpeihl)\
**Post date:** [October 12, 2020, 4:42pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/2 "2020-10-12T16:42:21Z")

</div>

Hi @Kenneth_M_Kolano. We need a little more information. Which release did you update from and which release did you update to?

---

<div class="post-metadata">

**Author:** ![Kenneth\_M\_Kolano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kenneth_m_kolano/32/38752_2.png) [@Kenneth\_M\_Kolano](https://discuss.elastic.co/u/Kenneth_M_Kolano)\
**Post date:** [October 13, 2020, 1:15am UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/3 "2020-10-13T01:15:38Z")

</div>

Formerly working version is 7.8.0, broken updated version 7.9.2.

---

<div class="post-metadata">

**Author:** ![nickpeihl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nickpeihl/32/112622_2.png) [@nickpeihl](https://discuss.elastic.co/u/nickpeihl)\
**Post date:** [October 13, 2020, 4:36pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/4 "2020-10-13T16:36:17Z")

</div>

Thanks @Kenneth_M_Kolano. How are you importing your old visualizations into the new release? Usually, the [upgrade process](https://www.elastic.co/guide/en/kibana/current/upgrade.html) automatically migrates your visualizations and dashboards.

---

<div class="post-metadata">

**Author:** ![Kenneth\_M\_Kolano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kenneth_m_kolano/32/38752_2.png) [@Kenneth\_M\_Kolano](https://discuss.elastic.co/u/Kenneth_M_Kolano)\
**Post date:** [October 13, 2020, 5:30pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/5 "2020-10-13T17:30:02Z")

</div>

This is against a fresh install, with the indexes / dashboards imported. The install config process shown below...

```
echo -e "\nAwait Kibana startup"
if curl -s -S --retry 10 --retry-connrefused -f http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings; then
	echo -e "\n\nSet Kibana index patterns"
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/saved_objects/index-pattern/eve-* -H 'Content-Type: application/json' -H 'kbn-xsrf: anything' -d @./Installation/kibana/default_index_pattern.json
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/saved_objects/index-pattern/file-analysis -H 'Content-Type: application/json' -H 'kbn-xsrf: anything' -d @./Installation/kibana/YYY_index_pattern.json
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/saved_objects/index-pattern/device-details -H 'Content-Type: application/json' -H 'kbn-xsrf: anything' -d @./Installation/kibana/ZZZ_index_pattern.json

	echo -e "\n\nSet Kibana date format"
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings/dateFormat -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value": "YY-MM-DD HH:mm:ss.SSS"}'

	echo -e "\n\nHide the default Time field" #Time related fields will need to be manually added, would be preferable if this could be set per Saved Search, refer: https://github.com/elastic/kibana/pull/23897
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings/doc_table:hideTimeColumn -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value":true}'

	echo -e "\n\nSet Kibana default index pattern"
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings/defaultIndex -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value": "XXX-*"}'

	echo -e "\n\nSet Kibana Discovery search size"
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings/discover:sampleSize -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value": "1000"}'

	echo -e "\n\nSet Kibana Timelion max buckets" 	
	#This allows >1d of results on BBB dashboard
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings/timelion:max_buckets -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value": "10000"}'

	echo -e "\n\nHide Kibana fields found outside of source"
	#Though we only want "_source" here, the 7.3 release results in "child "meta_fields" fails because ["meta_fields" must be an array]" errors if this is set to a singular value, refer: https://github.com/elastic/kibana/issues/43167
	#curl --connect-timeout 15 -s -S -X POST http://localhost:5601/kibana/api/kibana/settings/metaFields -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value": ["_source"]}'
	curl --connect-timeout 15 -s -S -X POST http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/settings/metaFields -H "Content-Type: application/json" -H "kbn-xsrf: true" -d '{"value": ["_source","_id"]}'

	echo -e "\n\nImport Kibana Dashboards"
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/AAA\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/AAA\ Reports\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/BBB\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/CCC\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/DDD\ Events\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/EEE\ Reports\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/EEE\ Dashboard.json
	curl --connect-timeout 15 -s -S -X POST "http://elastic:$elasticsearch_pass@localhost:5601/kibana/api/kibana/dashboards/import?exclude=index-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d @./Installation/kibana/FFF\ Dashboard.json
else
	echo -e "\nError starting Kibana, unable to configure"
fi
```

---

<div class="post-metadata">

**Author:** ![nickpeihl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nickpeihl/32/112622_2.png) [@nickpeihl](https://discuss.elastic.co/u/nickpeihl)\
**Post date:** [October 13, 2020, 7:01pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/6 "2020-10-13T19:01:01Z")

</div>

Hi @Kenneth_M_Kolano. I'm not able to recreate the issue. I tried importing a dashboard from 7.8.0 into 7.9.2 but did not get the same errors as you. Probably there is a situation unique to your saved objects that is causing the error. I wonder if you can create a reproducible example? Then we can file a bug report to get it fixed.

---

<div class="post-metadata">

**Author:** ![Kenneth\_M\_Kolano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kenneth_m_kolano/32/38752_2.png) [@Kenneth\_M\_Kolano](https://discuss.elastic.co/u/Kenneth_M_Kolano)\
**Post date:** [October 15, 2020, 2:18am UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/7 "2020-10-15T02:18:29Z")

</div>

So things mysteriously started working tonight. This seems to be related to logging in as the "elastic" admin user, rather than just as an alternate user set up for my application.

Is there now some sort of initialization that occurs on the initial admin user login? How can I automate such to enable an install without further interaction?

---

<div class="post-metadata">

**Author:** ![nickpeihl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nickpeihl/32/112622_2.png) [@nickpeihl](https://discuss.elastic.co/u/nickpeihl)\
**Post date:** [October 15, 2020, 6:45pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/8 "2020-10-15T18:45:20Z")

</div>

Hi @Kenneth_M_Kolano. I'm glad you got it working.

> Is there now some sort of initialization that occurs on the initial admin user login? How can I automate such to enable an install without further interaction?

There is a saved object initialization that occurs on login. But it's difficult to see if this is related unless we can find a reproducible bug.

---

<div class="post-metadata">

**Author:** ![Kenneth\_M\_Kolano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kenneth_m_kolano/32/38752_2.png) [@Kenneth\_M\_Kolano](https://discuss.elastic.co/u/Kenneth_M_Kolano)\
**Post date:** [October 22, 2020, 7:05pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/9 "2020-10-22T19:05:37Z")

</div>

I can easily and repeatably reproduce this, though it will take me some time to pull together a script to allow others to do so, as it requires generating new users and a few additional steps to setup indexes/visualizations.

More or less until the "elastic" user logs in and access a visualization on an index, other users accessing visualizations/saved searches get a "this.uiSettings is undefined" error.

---

<div class="post-metadata">

**Author:** ![Kenneth\_M\_Kolano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kenneth_m_kolano/32/38752_2.png) [@Kenneth\_M\_Kolano](https://discuss.elastic.co/u/Kenneth_M_Kolano)\
**Post date:** [November 15, 2020, 10:10pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/10 "2020-11-15T22:10:12Z")

</div>

This seems to be resolved with 7.10

---

<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:** [December 13, 2020, 10:10pm UTC](https://discuss.elastic.co/t/this-uisettings-is-undefined/251689/11 "2020-12-13T22:10:31Z")

</div>

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