RosiKyu commented on PR #14484:
URL: https://github.com/apache/cloudstack/pull/14484#issuecomment-6956149083

   @Pearl1594 I've re-tested, the bitmap removal fix works: with the VM stopped 
and its disk moved so it is active on another host, the snapshot delete 
succeeds and goes to the host holding the disk. More regression and negative 
tests passed too: detached disk, plain CLVM, revert and volume/template from a 
snapshot with the disk on another host than the stopped VM's last host, VM 
moved between hosts, two snapshots at once, snapshot while the VM starts, host 
reboot.
   
   **One problem found:** after deleting a snapshot that has a newer snapshot 
after it and restarting the VM, every new snapshot of the CLVM_NG disk fails 
with only "internal error". Moving the disk to the other CLVM_NG pool does not 
help. Reproduced 3 out of 3 times, with the VM running or stopped at the time 
of the delete.
   
   Steps to reproduce:
   1. VM V running, with data disk D on a CLVM_NG pool. Take snapshots S1, S2, 
S3 of D.
   2. Delete S2.
   3. Stop V and start it again.
   4. Take a snapshot of D: it fails, and so does every later snapshot of D. 
Expected: it succeeds (as an incremental on S3, or as a new full).
   
   On the start in step 3 the host cannot restore the checkpoint of S3 because 
its parent (S2) is gone, so the snapshot in step 4 cannot find it.
   
   Lab mapping: `host H = 10.0.33.153` (kvm4), VM V = `vm-t1` (i-2-8-VM), disk 
D = `t3-vol-from-r2` (9c4e4023-95ac-462d-b19d-a2e65b2ff60e), S1/S2/S3 = 
`F-1`/`F-2`/`F-3`, S2 checkpoint = `608c158e-6241-4bfa-a72e-4b4d9f731d73`, S3 
checkpoint = `ae9e8d14-b2d3-4c86-bb44-81499cbbf314`.
   
   **API, steps 1 to 4: S2 deleted, VM restarted, the next snapshot fails**
   ```
     F-1: jobstatus 1
     F-2: jobstatus 1
     F-3: jobstatus 1
     -- delete F-2 (middle), VM running, 17:18:11
     delete F-2: jobstatus 1 {"success": true}
     stop vm-t1: jobstatus 1
     start vm-t1: jobstatus 1
     vm-t1: Running kvm4
     -- snapshot F-4 after the restart, 17:19:05
     F-4: jobstatus 2 "errortext": "Failed to create Snapshot due to an 
internal error creating Snapshot for volume 
9c4e4023-95ac-462d-b19d-a2e65b2ff60e"
   ```
   
   **Host H, steps 3 and 4: the checkpoint of S3 cannot be restored because S2 
is gone, then the snapshot fails (the first line is the same problem on another 
disk from an earlier run)**
   ```
   [root@ref-trl-12929-k-mol8-rositsa-kyuchukova-kvm4 ~]# grep -E 'for moment 
.* not found|for incremental backup of disk .* not found' 
/var/log/cloudstack/agent/agent.log | grep encountered | grep "2026-11-17 17:19"
   2026-11-17 17:19:02,138 WARN  [utils.script.Script] 
(AgentRequest-Handler-2:[]) (logid:168923cf) Process [4118] for command 
[/bin/bash -c virsh checkpoint-create --domain i-2-8-VM --xmlfile 
/mnt/5ad757a4-e9f9-3a5c-8dc7-0e0ea7bc5136/checkpoints/2/19/a94cc206-e5e9-431f-aae4-fcdda50052dd
 --redefine ] encountered the error: [error: invalid argument: parent 
766c7f8d-2a66-45e4-acc1-5665e6943254 for moment 
a94cc206-e5e9-431f-aae4-fcdda50052dd not found].
   2026-11-17 17:19:03,492 WARN  [utils.script.Script] 
(AgentRequest-Handler-2:[]) (logid:168923cf) Process [4155] for command 
[/bin/bash -c virsh checkpoint-create --domain i-2-8-VM --xmlfile 
/mnt/5ad757a4-e9f9-3a5c-8dc7-0e0ea7bc5136/checkpoints/2/22/ae9e8d14-b2d3-4c86-bb44-81499cbbf314
 --redefine ] encountered the error: [error: invalid argument: parent 
608c158e-6241-4bfa-a72e-4b4d9f731d73 for moment 
ae9e8d14-b2d3-4c86-bb44-81499cbbf314 not found].
   2026-11-17 17:19:08,538 WARN  [utils.script.Script] 
(AgentRequest-Handler-5:[]) (logid:3bd71886) Process [4174] for command 
[/bin/bash -c virsh backup-begin --domain i-2-8-VM --backupxml 
/tmp/cloudstack/backupXMLs/a78027f1-c530-49e8-aaf1-23be517a74b9 --checkpointxml 
/tmp/cloudstack/checkpointXMLs/a78027f1-c530-49e8-aaf1-23be517a74b9 ] 
encountered the error: [error: Domain checkpoint not found: Checkpoint 
'ae9e8d14-b2d3-4c86-bb44-81499cbbf314' for incremental backup of disk 'vdf' not 
found].
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to