All Products
Search
Document Center

Simple Log Service:Migrate Kibana dashboards

Last Updated:Mar 25, 2026

This guide explains how to migrate existing Kibana dashboards to a new Kibana instance connected to Simple Log Service (SLS) after you migrate your data.

Overview

image
  1. Export the dashboard saved objects from your source Kibana instance as an export.ndjson file.

  2. Replace the source index pattern ID in the export.ndjson file with the new index pattern ID.

  3. Import the modified export.ndjson file into your new Kibana instance.

Procedure

1. Prepare source environment and export dashboards

  1. Write the following sample data to your source Elasticsearch instance.

    POST people/_bulk
    { "index": {} }
    { "name": "Alice", "age": 30 }
    { "index": {} }
    { "name": "Bob", "age": 25 }
    { "index": {} }
    { "name": "Charlie", "age": 35 }
  2. In your source Kibana, create two dashboards based on the people index, named People Dashboard and People Names.

    image

  3. Create a sample chart within the People Dashboard.

    image

  4. Navigate to Stack Management > Saved Objects. On the Saved Objects page, select the dashboards that you want to export. Ensure that the Include related objects checkbox is cleared, and then export the objects. This action saves the dashboard definitions to an export.ndjson file.

    image

2. Prepare the target environment

  1. Log on to the Simple Log Service console.

  2. In the Projects section, click the one you want.

    image

  3. Write the same log data to your logstore. Ensure that the field names and types match those in the source Elasticsearch instance.

    Note

    The fields in your source Elasticsearch must match the fields in your target logstore. Mismatched fields can cause errors, such as "field not found", when you open the migrated dashboard.

    image

  4. Deploy a new Kibana instance and connect it to SLS. For more information, see Connect to Kibana.

    Note

    Use the same versions of Elasticsearch and Kibana for both the source and target environments.

  5. After you connect to SLS using Docker Compose or a Helm chart, Kibana automatically creates the corresponding index pattern.

    image

3. Perform the migration

  1. Find the ID of the index pattern in your source Elasticsearch. The kibana_config_1.json file is as follows:

    {
        "url" : "http://xxx:5601",
        "user" : "elastic",
        "password" : "",
        "space" :  "default"
    }

    Run the following command using the ptn_list.py script to find the index pattern ID.

    ➜  python ptn_list.py kibana_config_1.json
    f06fc2b0-****-****-****-15adf26175c7    people

    In the output, f06fc2b0-****-****-****-15adf26175c7 is the ID of the source people index pattern. You can find references to this ID in the exported export.ndjson file.

    image

  2. Find the ID of the new index pattern in the Kibana instance connected to SLS.

    Use the ptn_list.py script again to find the ID of the index pattern in the new Kibana.

    # Prepare kibana_config_2.json
    
    ➜  python ptn_list.py kibana_config_2.json
    ef710470-****-****-****-ad198b7b763d	etl.people

    Run the sed command to replace all occurrences of the old ID with the new one in the export.ndjson file.

    sed -i 's/f06fc2b0-****-****-****-15adf26175c7/ef710470-****-****-****-ad198b7b763d/' export.ndjson
  3. In your new Kibana instance, navigate to Stack Management > Saved Objects. On the Saved Objects page, click Import and upload the modified export.ndjson file. A success message appears after the import completes.

    image

  4. Open the newly imported dashboards to verify the results.

    image