Mapping for Bytes/percentage in kibana

Hi,
Is there a way to define automatically the format for some fields via a custom mapping?
I’m talking about the BYTES or Percentage format.
I dont want each time to manually set the mapping on a new installed elasticsearch index/machine.

In other words - I want to be able to import my mapping into kibana and have it with the special percentage/bytes format for some fields.

The field formats are part of the Index Pattern documents in the .kibana index. Most of the time, saved objects in Kibana can be exported to a backup and then re-imported to restore the backup, but unfortunately, Index Pattern objects are not exported. There is an open issue in Github on this: https://github.com/elastic/kibana/issues/4288

The alternative to using exported saved objects is to create a snapshot that includes your .kibana index. This is done using Elasticsearch APIs: https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-snapshots.html

If you make a snapshot of your .kibana index, then you can restore that into newly installed clusters, and then you'll be able to preserve all index patterns and their formatted fields.

Hope that helps!

1 Like

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