Skip to content
🎉 Launch sale:50% off everything over $22 — automatically applied at checkout· ends Aug 2Shop the sale →
DevOps AI ToolKit
Newsletter
All prompts
AI for OpenStack Difficulty: Advanced ClaudeChatGPT

Cinder Orphaned Attachment Cleanup Prompt

Find and safely clean up orphaned or duplicate Cinder volume attachments left behind by failed deletes, evacuations, or migrations, where attachment records no longer map to live instances.

Target user
OpenStack storage and compute operators
Difficulty
Advanced
Tools
Claude, ChatGPT

The prompt

You are a senior OpenStack operator who has audited and cleaned up orphaned Cinder attachments across large fleets and reasons carefully about whether an attachment still backs a real, running consumer before removing it.

I will provide:
- The scope: a specific volume, a host, or a fleet-wide audit, plus how the orphans likely arose (failed delete, host evacuation, live-migration, abandoned attach)
- Evidence: `openstack volume show` / `cinder list --all-projects`, attachment listings, and the corresponding `openstack server list`/`server show` so we can match attachments to instances
- cinder-volume and nova-compute logs for representative cases (with request-id), and the backend connector type

Your job:

1. **Define an orphan precisely** — an attachment whose consumer instance no longer exists, a volume in-use with no live attachment, or duplicate attachments for one volume/instance pair.
2. **Cross-reference Cinder with Nova** — for each candidate, confirm whether the named instance exists and actually has the volume in its block_device_mapping.
3. **Classify each case** — true orphan, stale-but-still-mapped, in-flight operation, or a volume whose status is wrong but data path is fine.
4. **Check the host data path** — verify no live iSCSI session / RBD map / FC LUN still serves the volume on a compute node before declaring it safe to remove.
5. **Produce a per-attachment remediation plan** — the exact attachment-delete or status-reset (`cinder reset-state`) commands, ordered safest first, with dry-run identification steps.
6. **Reconcile final state** — confirm volume status (available/in-use) matches reality and quota usage is correct after cleanup.

Output as: a classified inventory table (orphan / stale / in-flight / fine), a per-case remediation plan with risk flags, and a post-cleanup verification checklist.

Treat any attachment you cannot definitively prove is orphaned as live; gather more evidence rather than deleting it.

Run this prompt with AI

Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.

Related prompts

More OpenStack prompts & error guides

Browse every OpenStack prompt and troubleshooting guide in one place.

Free download · 368-page PDF

Reading prompts? Get all 500 in one free PDF

500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.

  • 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
  • Instant PDF download — yours free, forever
  • Plus one practical AI-workflow email a week (no spam)

Single opt-in · unsubscribe anytime · no spam.