Am 29.01.2026 um 22:20 hat Stefan Hajnoczi geschrieben: > v3: > - Use warn_report_err() instead of suppressing errors [Daniel Berrangé] > - Wrap lines exceeding 80 characters > > v2: > - Add user documentation [Paolo] > - Send PREEMPT on the source if migration fails. This rollback operation > ensures the source regains access to the LUN even if migration fails after > the destination issues its own PREEMPT. > > Live migration does not work for SCSI Persistent Reservations acquired on > scsi-block devices. This patch series migrates the reservation key and > reservation type so that the destination QEMU can take over the persistent > reservation with the PREEMPT service action upon live migration. > > The approach involves snooping PERSISTENT RESERVE OUT replies and tracking the > scsi-block device's current reservation key and reservation type. In most > cases > this involves no additional SCSI commands. This approach isn't perfect: if > another machine modifies the reservation on the physical LUN, then QEMU's > state > becomes stale. Persistent reservations are inherently cooperative, so this is > acceptable as long as real applications don't run into problems. > > I am also working on a test suite called pr-tests that runs sg_persist(8) > commands across multiple machines in order to exercise various scenarios: > https://gitlab.com/stefanha/pr-tests
On top of this, should we do something to catch cases where migrate-pr is off, but the user still tries to migrate while PRs are in use? Maybe have a migration blocker as long as pr_state->key is set? Kevin
