Migrating Multiple Grafana Instances into a Single Instance

In my organization, we are currently running several Grafana instances, each with its own database. To streamline operations and improve manageability, we are looking to consolidate these multiple instances into a single Grafana instance.

We are using Grafana Version 11 across all our instances, operating on Ubuntu 20.04 LTS. Each Grafana instance has been independently set up and maintains its own set of dashboards, data sources, and configurations.

To achieve consolidation, I plan to create a new Grafana instance that will serve as the unified platform for all our monitoring and visualization needs. The migration process will involve merging the databases from the existing instances into this new instance. This includes transferring all dashboards, data sources, user settings, and other configurations to ensure a seamless transition.

The goal is to successfully migrate all existing data and configurations to the new Grafana instance without any data loss or significant downtime. By consolidating, I expect to simplify management, enhance performance, and provide a more unified monitoring experience across the organization.

At this stage, I am in the planning phase and identifying potential challenges. These include ensuring compatibility of data formats, maintaining user permissions, and handling any custom plugins or integrations that may have been implemented in the individual instances.

I have reviewed various resources and documentation, including the Grafana official migration guide. However, additional guidance on best practices and potential pitfalls specific to my use case would be greatly appreciated. [Include links to specific guides or documentation if available.]

how many datasources and how many dashboards per instance?

is the backend for all 3 sqlite?

We have approximately 400 datasources on each Grafana instance and about 20,000 dashboards. For the backend, we use PostgreSQL.

:skull::eyes: wow, small shop eh?

are there duplicate dashboards and datasources?

Haha yeah!
There probably are duplicate data sources and dashboards. They might not have the exact same configuration, but they likely have the same names.

not sure if dashboard name has unique key in the db but ypu might run into uid collisions: user, dashboard, datasource etc.
many options here, choose your poison carefully but this should be doable

but first you will have to be intimately familiar with the back end schema, might want to involve a dba

a. I would do this using a scripting language such as python to iterate over all tables and recreate things on centralized db

b. or I wonder if you could leverage HA or some sort of synch so that all existing instanves synch their data over to the central instance, then one synched kill the synch

c. data dump into sql file from each instance, combine sql files, vet for dups, import into new instance

etc