[Workload]: dns-stress
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 48/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Tranquilla
- Stack tecnologico
- kubernetes, linux, shell
- Ambito
- devops, networking
Direzione di ricerca
La issue specifica /etc/virtwork/dns-queries.txt, /usr/local/bin/virtwork-dns-stress.sh e il contenuto cloud-init di virtwork-dns-stress.service. Inizia individuando nel repository le definizioni esistenti dei workload delle VM e i relativi punti di ingresso per il provisioning, quindi confronta come vengono rappresentati pacchetti, script e servizi. Il lavoro è completato quando una singola VM è in grado di sostenere il workload dnsperf configurato con la combinazione di query e i parametri documentati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Workload Name
dns-stress
Workload Description
High-rate DNS resolution workload that generates sustained DNS query volume from inside a VM. Produces configurable query patterns — A, AAAA, SRV, PTR record lookups — against both cluster-internal names (Kubernetes Service DNS) and external domains, exercising the full DNS resolution path from a KubeVirt VM through the pod network to CoreDNS.
DNS from VMs follows a different path than DNS from containers. A container's /etc/resolv.conf points directly to the CoreDNS ClusterIP. A KubeVirt VM's DNS resolution goes through the VM's internal resolver, out through the pod network interface, to CoreDNS — an additional network hop that is often the first thing to break under load or misconfiguration. Network partners, DNS partners, and anyone validating OVN-Kubernetes or SDN behavior need this signal.
Tooling and Packages
- Tool:
dnsperf(DNS performance testing tool from DNS-OARC) orqueryperf(BIND utility) - RPM packages:
dnsperf(available in EPEL) orbind-utils(forqueryperfanddig) - systemd service command:
dnsperf -s <dns-server> -d /etc/virtwork/dns-queries.txt -l 0 -Q 100-s <dns-server>: target DNS server (CoreDNS ClusterIP or VM's configured nameserver)-d <queryfile>: file containing query names and types-l 0: run indefinitely-Q 100: target 100 queries per second
- Configurable parameters:
dns-qps: target queries per second (default: 100)dns-server: target nameserver (default: auto-detect from/etc/resolv.conf)dns-query-mix: proportion of internal vs external queries (default: 70% internal, 30% external)dns-record-types: query types to generate (default: A, AAAA, SRV)
VM Count Model
Single VM (like cpu, memory, disk)
Required Resources
- Persistent storage (DataVolume)
- Kubernetes Service (for inter-VM communication)
- Kubernetes Secret (for credentials or config)
- Additional CPU/memory beyond defaults
- GPU or special device passthrough
Cloud-Init Details
packages:
- dnsperf
- bind-utils
write_files:
- path: /etc/virtwork/dns-queries.txt
content: |
kubernetes.default.svc.cluster.local A
kubernetes.default.svc.cluster.local AAAA
kube-dns.kube-system.svc.cluster.local A
kube-dns.kube-system.svc.cluster.local SRV
openshift-apiserver.openshift-apiserver.svc.cluster.local A
console.openshift-console.svc.cluster.local A
example.com A
example.com AAAA
www.google.com A
github.com A
dns.google A
_http._tcp.example.com SRV
1.0.0.127.in-addr.arpa PTR
- path: /usr/local/bin/virtwork-dns-stress.sh
permissions: '0755'
content: |
#!/bin/bash
set -euo pipefail
DNS_SERVER=$(awk '/^nameserver/{print $2; exit}' /etc/resolv.conf)
QPS="${DNS_QPS:-100}"
QUERY_FILE="${DNS_QUERY_FILE:-/etc/virtwork/dns-queries.txt}"
# dnsperf with -l 0 runs indefinitely
exec dnsperf \
-s "$DNS_SERVER" \
-d "$QUERY_FILE" \
-l 0 \
-Q "$QPS" \
-c 10 \
-S 30
- path: /etc/systemd/system/virtwork-dns-stress.service
content: |
[Unit]
Description=Virtwork DNS stress workload
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
Environment=DNS_QPS=100
ExecStart=/usr/local/bin/virtwork-dns-stress.sh
Restart=always
RestartSec=5
[Install]
WantedBy=multi-user.target
runcmd:
- systemctl enable --now virtwork-dns-stress.service
Use Case
- Network partners (CNI, SDN, OVN-Kubernetes): DNS is the first network service to degrade under load or misconfiguration. Sustained DNS query volume from VMs validates that the CNI correctly routes DNS traffic from the VM's network namespace through the pod network to CoreDNS. Partners need to prove their network product doesn't introduce DNS latency or packet loss on the VM-to-CoreDNS path.
- DNS/Service discovery partners (external-dns, CoreDNS plugin vendors): Need sustained query volume to validate custom CoreDNS plugins, response caching, and query logging under VM-sourced load. The mix of internal (cluster.local) and external queries exercises both the Kubernetes plugin and upstream forwarding.
- Security partners (DNS-based threat detection): Products that inspect DNS queries for threat indicators (DGA detection, C2 domain detection, DNS tunneling) need sustained DNS traffic to validate their detection pipelines. The configurable query file can include suspicious-looking domains for controlled testing.
- Observability partners: DNS latency is a critical SLI. Partners building DNS dashboards or alerting need a consistent query source to validate p50/p95/p99 DNS latency measurement from VMs. dnsperf outputs per-interval statistics (queries sent, responses received, latency percentiles) that pair directly with partner monitoring.
- Platform validation: Validates that CoreDNS scales correctly when VMs — not just pods — are generating DNS load. VMs often have different DNS caching behavior than containers (systemd-resolved, NetworkManager DNS caching), which can produce different query patterns.
Additional Context
dnsperfis the industry standard for DNS performance testing, maintained by DNS-OARC (DNS Operations, Analysis, and Research Center). It provides precise QPS control, latency statistics, and sustained operation — exactly what this workload needs.- The query file (
dns-queries.txt) is the primary tuning knob. The default mix of cluster-internal and external domains is a starting point; partners can customize it to include their specific service names, longer query chains, or domains that exercise specific DNS features (CNAME chains, wildcards, NXDOMAIN). - The 70/30 internal/external split in the default query file reflects a realistic VM workload: most DNS queries resolve Kubernetes services (databases, APIs, other VMs), with a minority resolving external services (package repos, API endpoints, telemetry).
- At 100 QPS from a single VM, this is a moderate DNS load. Scale by deploying multiple VMs (
--vm-count 5at 100 QPS each = 500 QPS total) or increasingdns-qpsto 1000+ for stress testing. CoreDNS on a typical OpenShift cluster handles 5,000-10,000 QPS comfortably; this workload can scale to find the ceiling. - dnsperf's
-S 30flag prints statistics every 30 seconds — these are the latency and throughput numbers that appear in logs and can be scraped by monitoring agents. - Consider also providing a fallback mode using a shell loop with
digfor environments wherednsperfis not available in EPEL:while true; do dig @$DNS_SERVER +short $(shuf -n1 /etc/virtwork/dns-queries.txt | cut -d' ' -f1); sleep 0.01; done. Lower precision but zero package dependencies beyondbind-utils.
- Lingua principale
- Go
- Stelle
- 0
- Fork
- 0
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Nessuna guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di opdev/virtwork
-
good first issue needs-triage size/L workload-request workload/variant
Difficoltà 5/5 Più di una settimana Idoneità per principianti 45/100
-
[Workload]: chaos-migrationApertaneeds-triage priority/awaiting-more-evidence size/XL workload-request workload/tier-2
Difficoltà 5/5 Più di una settimana Idoneità per principianti 48/100
-
[Workload]: disk-snapshotApertagood first issue needs-triage size/XL workload-request workload/variant
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
-
[Workload]: encryptionApertaneeds-triage size/L workload-request workload/tier-3
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
-
[Workload]: windowsApertaneeds-triage size/XXL workload-request workload/tier-3
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
Tutte le issue di opdev/virtwork
Issue simili
-
Mend: dependency security vulnerability
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
kube-tarian/sigrun#202 ·
-
question raised-by:verifier
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
medici-finance/assay#4013 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
tsukumogami/tsuku#2775 ·
I maintainer di solito rispondono entro 1 giorno
-
automation models
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 69/100
I maintainer di solito rispondono entro 1 giorno