Skip to main content
idle · azure

Idle Azure VM

resource types
1
rule IDs covered
1
severity
medium

What does ZopNight detect here?

Running Azure VMs averaging under 5% CPU over 30 days, with memory and network guards, get a recurring off-hours schedule sized by the measured idle fraction, never a one-shot deallocation. Reservation-covered VMs are instead right-sized via catalog rate deltas, and both paths abstain when pricing or schedule data is absent.

Signal and threshold

How ZopNight evaluates Idle Azure VM.
Field Value
Rule IDsRC-201
Categoryidle
Severitymedium
Metricnone — pure configuration read
Sourceidle_vm.go

A running VM with flat CPU over the lookback

  • resource.Status: statusSucceeded
  • MetricsAware: azureCPUMetricName over azureCPULookbackDays days

CPU floor, memory and network guards

Terminal window
azureCPUThreshold=5.0, azureCPULookbackDays=30 (memory-bound guard at 60%, network idle guard at 1 MB bytes/bucket)

Schedule on-demand, rightsize when committed

two branches, no fabricated fraction.

  • OnDemand path → schedule (not a one-shot deallocate). A one-shot stop on a running VM is an indefinite outage, not a cost lever; idle or non-prod compute gets a recurring off-hours schedule. The dollar figure is the measured idle fraction from the aggregator’s heatmap (SetScheduleData, sd.IdlePercentage): savings = cost × sd.IdlePercentage, category schedule. The previous azureComputeOnlySavings × schedulingFallbackSavings (0.67) static fraction is removed; absent or zero schedule data => abstain (returns nil), never a flat fraction, never $0.
  • Committed (RI/SP) path → rightsize. Deallocation saves nothing (commitment bills regardless), so the rule rightsizes via catalog-diff (srcRate − dstRate) × 730 (idleVMRightsizeSavings → DeriveCatalogDiffSavings(…, 0)) with no flat-fraction fallback; it abstains when either rate is absent/≤0 (azureIdleRightsizingSavingsFraction 0.75 lingers in constants.go but is not consumed on this path), category rightsizing. Description notes “managed disk storage continues to bill”. Both paths abstain when pricing is absent (cost ≤ 0). EvalContextRule: a VM with a known active schedule or measured-and-near-off uptime (long-off hysteresis) is suppressed.

Scheduling off hours instead of leaving it stopped

  1. Review Azure Monitor CPU, memory, and network metrics for this VM
  2. Verify no workloads depend on this VM
  3. Apply the recommended recurring off-hours schedule (auto start/stop); do not leave it deallocated indefinitely
  4. Note that managed disk storage keeps billing while the VM is stopped

The single CPU series this rule reads

azureCPUMetricName (azureCPULookbackDays day lookback)

See it fire on your bill.

Connect an account read-only. The first findings land in minutes.

417 rule families across 353 resource types on 22 platforms. Every threshold, metric, and IAM action is documented on these pages before you grant anything.

417 rule families documented
353 resource types covered
read-only default access level
Multi-cloud automation· Production-ready in 30 min· SOC 2 · ISO 27001· 20–60% off the bill, first month· 4 platforms · 1 console· Multi-cloud automation· Production-ready in 30 min· SOC 2 · ISO 27001· 20–60% off the bill, first month· 4 platforms · 1 console·