Skip to content
DevOps AI ToolKit
Newsletter
All prompts
AI for OpenStack Difficulty: Advanced ClaudeChatGPT

Placement Inventory & Allocation Reconcile Prompt

Audit and reconcile the OpenStack Placement service for resource-provider inventory drift, leaked/orphaned allocations, and incorrect allocation ratios that cause phantom 'full' hypervisors or scheduling failures.

Target user
OpenStack operators managing Nova/Placement capacity
Difficulty
Advanced
Tools
Claude, ChatGPT

The prompt

You are a senior OpenStack operator auditing the Placement service for inventory drift and leaked allocations that make hypervisors appear full when VMs have been deleted or migrated. Work in read-only/advisory mode: `placement` allocation deletes and inventory edits are destructive, so propose them with explicit safeguards.

I will provide:
- Per-provider inventory and usage: `openstack resource provider list`, `openstack resource provider inventory list <rp>`, and `openstack resource provider usage show <rp>` for the suspect hosts.
- The set of allocations: `openstack resource provider allocation ... ` / `openstack allocation ... ` output, plus the live instance list on that host (`openstack server list --host <h> --all-projects`).
- nova-compute logs and whether `nova-manage placement heal_allocations` / `audit` has been run.
- The configured allocation ratios (cpu/ram/disk) and reserved values per provider.

Your tasks:

1. **Compute the truth table** — for VCPU, MEMORY_MB, DISK_GB: total = inventory*ratio - reserved; used = sum of allocations; and compare against the actual live instances on the host.
2. **Find leaked allocations** — list allocation consumers (instance UUIDs) that have no corresponding live server; these are the orphans inflating usage.
3. **Detect inventory drift** — flag where reported inventory disagrees with the real hardware (e.g. after a RAM/CPU change the compute didn't re-report).
4. **Recommend the safe repair** — prefer `nova-manage placement heal_allocations` and `nova-manage placement audit` over manual allocation deletes; only delete a specific orphaned allocation when the consumer is provably gone.
5. **Validate ratios** — confirm allocation ratios/reserved match the operator's overcommit policy.

Output: (a) per-resource truth table, (b) list of orphaned consumers with evidence, (c) ordered repair commands (heal/audit first), (d) verification step re-showing usage.

Related prompts

Newsletter

Free: the DevOps AI Incident-Triage Cheat Sheet

Subscribe and we’ll send you the one-page cheat sheet — plus weekly AI prompts, automation ideas, and tool reviews for infrastructure engineers. One email a week. No spam, unsubscribe anytime.

  • AI Incident-Triage Cheat Sheet (PDF)
  • Access to 2,104 DevOps AI prompts
  • One practical workflow email per week