Skip to content
CloudOps
Newsletter
All prompts
AI for OpenStack Difficulty: Intermediate ClaudeChatGPT

Neutron QoS & Rate Limiting Design Prompt

Design Neutron QoS policies — bandwidth limits, DSCP marking, minimum guarantee, OVS vs OVN driver differences.

Target user
Network engineers implementing QoS on OpenStack
Difficulty
Intermediate
Tools
Claude, ChatGPT

The prompt

You are a senior OpenStack network engineer who has implemented QoS policies in production — bandwidth limit per tenant, DSCP marking for sensitive traffic, minimum bandwidth guarantee.

I will provide:
- The QoS need (limit per port, per network, DSCP for app, guarantee min)
- The Neutron backend (OVS, OVN)
- The plan (creating new policy / debugging existing)
- Policy as currently configured

Your job:

1. **QoS rule types**:
   - **bandwidth_limit** — egress and ingress cap
   - **dscp_marking** — DSCP value for outgoing packets
   - **minimum_bandwidth** — guarantee floor (limited driver support)
   - **packet_rate_limit** — packets-per-second cap
2. **Apply at**:
   - **Port** — most granular
   - **Network** — default for all ports unless overridden
   - **Tenant default** — via admin policy
3. **Driver support**:
   - OVS — bandwidth_limit (TC-based), dscp_marking
   - OVN — bandwidth_limit per LSP, dscp_marking
   - Different backends may not support all rules
4. **For bandwidth limit**:
   - `max_kbps` and `max_burst_kbps`
   - Direction: ingress / egress
   - Egress easy (apply at sending side); ingress trickier
5. **For DSCP**:
   - Value 0-63 (6-bit)
   - Used by upstream routers for QoS
   - Common: EF (46) for VoIP, AF41 (34) for video
6. **For minimum bandwidth**:
   - Requires placement-aware scheduler
   - Resource provider reports egress_bw capacity
   - Allocations during VM scheduling
7. **For application**:
   - `openstack network qos policy create`
   - `openstack network qos rule create`
   - Apply to port/network via `--qos-policy`

Mark DESTRUCTIVE: applying bandwidth limit to gateway port (chokes traffic), modifying policy in use without notice (affects all referencing resources), removing minimum guarantee on a critical workload.

---

QoS need: [DESCRIBE]
Backend: [OVS / OVN]
Current policy: [DESCRIBE]
Goal: [design / debug / tune]

Why this prompt works

QoS is “set and forget” for many ops teams; subtle issues appear only under load. This prompt covers the design and debug pieces.

How to use it

  1. Pick rules based on need.
  2. Verify backend supports chosen rules.
  3. Test with iperf under load to validate.
  4. For minimum guarantee, ensure resource provider config.

Useful commands

# Create policy
openstack network qos policy create web-tier

# Add rules
openstack network qos rule create web-tier \
    --type bandwidth-limit \
    --max-kbps 100000 \
    --max-burst-kbps 10000 \
    --egress

openstack network qos rule create web-tier \
    --type dscp-marking \
    --dscp-mark 46

# Apply to port
openstack port set --qos-policy web-tier <port-id>

# Apply to network (default for new ports)
openstack network set --qos-policy web-tier <network-id>

# Inspect
openstack network qos policy show web-tier
openstack network qos rule list web-tier

# Verify on compute (OVS)
sudo ovs-vsctl list qos
sudo ovs-vsctl list queue
sudo tc qdisc show dev tap...

# Verify DSCP marking (in pod, after applying policy)
tcpdump -i eth0 -v 'ip[1] & 0xfc != 0'

Common findings this catches

  • bandwidth_limit not enforcing → driver doesn’t support direction; check backend.
  • DSCP marking not visible upstream → router not respecting; or kernel rewriting.
  • minimum_bandwidth not actually allocated → placement service not configured for bw resource provider.
  • Policy applied but old ports unchanged → port-level QoS sticks; reapply.
  • Burst too low for bursty workloads → tune.
  • Cross-policy conflict → port-level overrides network-level.

When to escalate

  • QoS performance issues under specific patterns — capture trace.
  • Upstream router QoS coordination — network team.
  • Complex multi-rule interactions — staged testing.

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 1,603 DevOps AI prompts
  • One practical workflow email per week