[Bug] Migration - Auto (Pre-Sync + Delta)
Hey there! π Thanks for taking the time to report this bug β we appreciate it!
Please keep in mind: PegaProx is developed and maintained entirely by volunteers in our free time. We do our best, but we can't work magic πͺ β please be patient, we'll get to your issue as soon as we can.
Want to help keep PegaProx alive?
- β Star the project β it's free and helps a lot!
- π Become a Sponsor β helps us dedicate more time to development
- π€ Contributing code or docs is always welcome too!
Describe the bug
Migrating VM's with Pegaprox. The delta sync shows complete in log but changes aren't sent across.
Steps to Reproduce
- Configure Migration settings
- Choose auto (pre-sync+delta)
- We choose 'wait for my confirmation before switchover'
- Once at waiting for failover, we manually create new content on the source VM
- We complete the migration but these changes aren't seen on the new VM.
Expected behavior
Are delta changes instant?
Environment
- **PegaProx Version: 1.2.0
- Installation Method:
- OS:
- Browser: Edge
- Behind Reverse Proxy?
- UI?
Logs
[13:16:11] disk0: 81% (48.82/60.00 GB, ~149 MB/s) [13:16:44] disk0: still copyingβ¦ 89% (53.64/60.00 GB, ~149 MB/s) [13:16:50] disk0: 91% (54.64/60.00 GB, ~149 MB/s) [13:17:23] disk0: still copyingβ¦ 99% (59.53/60.00 GB, ~149 MB/s) [13:17:31] SSH: GiB) copied, 407 s, 157 MB/s 64109953024 bytes (64 GB, 60 GiB) copied, 408 s, 157 MB/s 64281919488 bytes (64 GB, 60 GiB) copied, 409 s, 157 MB/s 0+3897200 records in 0+3897200 records out 64424509440 bytes (64 GB, 60 GiB) copied, 415.631 s, 155 MB/s [13:17:31] SSH OK: 60.00 GB [13:17:33] Disk 0: cloned β transferred β attached as sata0 [13:17:37] EFI fallback: registering BOOTX64.EFI on /dev/datstore-PROX/vm-110-disk-0 [13:17:37] EFI fallback loader: fallback loader already in place [13:17:37] Phase: awaiting_confirmation [13:17:37] === HOLD FOR CONFIRMATION: disks are staged and the source VM is STILL RUNNING on VMware. The switchover (suspend source β start target) will happen only when you confirm. Drain traffic / flip DNS now, then commit. === [13:22:07] === Operator confirmed β proceeding with the switchover now. === [13:22:07] Phase: delta_sync [13:22:07] Phase: cutover [13:22:07] === CUTOVER: suspending source, starting target === [13:22:10] === CUTOVER DONE (downtime ~3.0s) === [13:22:10] Phase: verify [13:22:13] Phase: cleanup [13:24:17] Phase: completed [13:24:17] COMPLETED (vmkfstools_clone, downtime ~3.0s): VAMT -> VMID 110
## Screenshots
<!-- If applicable, add screenshots to help explain the problem. -->
## Checklist
- [ ] I have searched existing issues to make sure this is not a duplicate
- [ ] I am using the latest version of PegaProx
- [ ] I've put enough in here that someone can start on it without asking me three questions first
- [ ] I understand PegaProx is maintained by volunteers in their free time. Nobody is on call, and writing URGENT doesn't get anyone out of bed πͺ
Hey, thanks for the clear repro, that's a real bug. In auto mode the copy runs from a snapshot taken when the migration starts, and that path doesn't replay the changes made after it before switching over. Your log shows it: the delta step goes straight to cutover. So anything written to the source after the copy began, including during the hold, is missing on the target.
Until that's fixed, the safe way is to shut the source VM down before you start the migration, then the copy is the final state. If the migrated VM is already in use, it's worth checking for data written on the source during that window.
If PegaProx saves you time, a small tip on OpenCollective helps us keep at it.
Thanks for the reply, is this a bug that's being actively worked on?
We were hoping we could use the delta sync for production services, i.e. file server as these are large they could be replicated during the day, and delta changes synced over out of hours.
Is this is a bug in all versions or just the version we are running?
Fixed in 1.3.0, which is out now. To your questions: it affected the Live Clone and Auto modes in 1.2.0 and the releases before it since June. In 1.3.0 the switchover stops the source, waits until ESXi has folded the snapshot back, compares every 256 MiB block of the disks with the copy, transfers what changed and reads those blocks back, and only then starts the target. We ran it on a 90 GB Windows guest that kept writing during the hold, and afterwards all 360 blocks of source and target matched. The catch is that the switchover now reads each disk once on ESXi, so the downtime grows with the disk size; for big file servers with a short window, Live Mirror is the quicker mode.
If this one made your week easier, https://opencollective.com/pegaprox is where the project gets its funding.
Marcus