Orphaned Azure Snapshot
What does ZopNight detect here?
Snapshots whose source managed disk has been deleted are rolled up per subscription and region; the rule fires when the rollup is active with more than 0 orphan snapshots and a positive priced cost. Savings equal the rollup's price: provisioned GB times the per-GB rate times 730. That is an upper-bound estimate.
Signal and threshold
| Field | Value |
|---|---|
| Rule IDs | RC-242 |
| Category | orphan |
| Severity | low |
| Metric | none — pure configuration read |
| Source | snapshot_orphan.go |
Where it applies
Orphan snapshots arrive as a regional rollup
- Re-keyed onto the discoverer’s per-subscription+region ROLLUP resource of type azure-snapshot-orphan (snapshots whose source disk has been deleted are aggregated into this rollup rather than surfacing as a standalone parentless azure-snapshot). Gates: resource.Status EqualFold “active” and resource.UnitCount > 0 (number of orphan snapshots aggregated into the rollup). resource.SizeGB, when present, is included in the recommendation text.
Provisioned size as an upper bound estimate
The rule is concrete or it abstains. CurrentCostUSD = SavingsUSD = r.pricing[UID], OptimizedCostUSD = 0; abstains (returns nil) when pricing is missing or ≤ 0; it never emits a zero-cost recommendation. The pricing layer prices the rollup on SizeGB × snapshot-standard per-GB rate × 730 (service.go buildResourceCostMap), where SizeGB is the sum of each orphan snapshot’s provisioned diskSizeGB. Azure bills managed-disk snapshots on used/delta data size, not provisioned capacity, so for sparse/large disks this is a directionally-correct upper-bound estimate of the true bill, not an exact figure. Byte-accurate billed size is not available from the discoverer’s current Resource Graph query (properties.diskSizeGB is always provisioned capacity) and would require a separate Azure Cost Management / Consumption Usage Details producer keyed by snapshot resourceId, which is out of scope for this rule.
Deleting snapshots after checking dependents
- Confirm the source disks have been deleted and the data is no longer needed
- If data may be required, create a new managed disk from the snapshot first
- Go to Azure Portal → Snapshots → filter by region → Select → Delete
- Verify no restore points or images depend on these snapshots