Proxmox migrate container

Proxmoxuser41

New Member
Sep 13, 2022
9
0
1
Hello Forum
If i want to migrate a container via GUI, it first shuts down and then the data is copied. This takes a lot time. When migrating, why isn't data first copied and then shut down? When migrating a productive system, you want to keep the downtime as low as possible. You can manually do a replication first and then migrate the system after, but why isn't it done that way with a migration?
 
How it is done exactly depends a lot on how the cluster is set up.
If you have the disk of the container on a shared storage (network share, Ceph, etc), you will only see the container do a quick shutdown & boot.

If the container is on a local storage, then the disk needs to be migrated as well. One way to improve it, is if you use ZFS on the involved nodes and set up a replication job. This way, only the changes since the last successful replication needs to be transferred.
 
How it is done exactly depends a lot on how the cluster is set up.
If you have the disk of the container on a shared storage (network share, Ceph, etc), you will only see the container do a quick shutdown & boot.

If the container is on a local storage, then the disk needs to be migrated as well. One way to improve it, is if you use ZFS on the involved nodes and set up a replication job. This way, only the changes since the last successful replication needs to be transferred.
Our cluster is set up with local storage. we know that the migration with a replication is very fast. but the question is why is the system first shut down during a migration and only then copied? Depending on the system, this process can take a long time. why don't you first copy the data during a migration like with a replication and then shut down the system and start it up on the target?
 
see the linked bug. it's technically possible (we use a similar approach/two-phase rsync for "suspend" mode backups for containers), but it's not implemented (yet). there's also the question of whether to use file-level incremental syncs (works for *all* storages, but doesn't re-use replication) or rely on the storage level (where only ZFS is implemented so far).