Skip to content

fix(target): track owned volume attachments#155

Open
Rico Lin (ricolin) wants to merge 1 commit into
vexxhost:mainfrom
ricolin:fix/openstack-volume-attachment-ownership
Open

fix(target): track owned volume attachments#155
Rico Lin (ricolin) wants to merge 1 commit into
vexxhost:mainfrom
ricolin:fix/openstack-volume-attachment-ownership

Conversation

@ricolin

Copy link
Copy Markdown
Member

Summary

  • track when migratekit attaches an OpenStack volume itself
  • only detach volumes that were attached by the current migratekit run
  • preserve metadata-based auto-attach for volumes that are not already visible locally
  • add unit coverage for pre-attached and auto-attached volume paths

Tests

  • go test ./internal/target
  • PKG_CONFIG_PATH=$HOME/.cache/migratekit/libnbd-1.22.2-prefix/lib/pkgconfig CGO_CFLAGS=-I$HOME/.cache/migratekit/libnbd-1.22.2-prefix/include CGO_LDFLAGS=-L$HOME/.cache/migratekit/libnbd-1.22.2-prefix/lib LD_LIBRARY_PATH=$HOME/.cache/migratekit/libnbd-1.22.2-prefix/lib go test -a ./...

Record when migratekit attaches an OpenStack volume itself and only detach
that recorded attachment during cleanup. This preserves metadata-based
auto-attach while avoiding metadata lookup and detach for pre-attached
volumes.

Assisted-By: OpenAI <noreply@openai.com>
Signed-off-by: Rico Lin <rlin@vexxhost.com>
@ricolin Rico Lin (ricolin) force-pushed the fix/openstack-volume-attachment-ownership branch from 8688820 to 9f6c2f9 Compare May 22, 2026 08:10
@guilhermesteinmuller

this fix came based on this report from an user
image

@ricolin Rico Lin (ricolin) force-pushed the fix/openstack-volume-attachment-ownership branch from 9f6c2f9 to 3169585 Compare June 16, 2026 00:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants