How to migrate master to a new server and all the priviously collected data?


Our current netdata master is having RAM constraints.
We want to move to a bigger server.
How can we do this while keeping all the previously collected data?

Relevant docs you followed/actions you took to solve the issue

Nothing in docs.

Environment/Browser/Agent’s version etc


What I expected to happen

I expect to have one of the following way:

  1. Ansible playbook that does it for me
  2. documentation with clear steps so that no chances of losing the data
  3. replication that does it seamlessly

I am willing to contribute for the cause.

This is unfortunately not something we have properly documented anywhere at the moment, but in general you can usually migrate an install by shutting down Netdata on the source system, copying /var/lib/netdata, /var/cache/netdata, and /etc/netdata from the source system to the target system, and then explicitly removing the contents of /var/lib/netdata on the source system.

If you want to just preserve metrics and config, you can skip the handling of /var/lib/netdata, though if you use Netdata Cloud that will mean you need to claim the new system even the old one was claimed previously.

You should certainly try replication first, but you will need a more recent version of Netdata, which is much more reliable and performant for replication. Use the latest stable. If you have any issues and the data isn’t completely replicated, it will be a bug that we’ll need to address.

Created a new feature request: [Feat]: Add support for offline migration of a Netdata install · Issue #14764 · netdata/netdata · GitHub