Prompt
How do I use synthetic monitoring for CDN or DNS issues?
Latest observation
Synthetic monitoring is very useful for catching CDN and DNS problems before users report them, because it lets you probe from known locations on a schedule and compare behavior over time.
What to monitor
For DNS
Use synthetic checks to validate:
- Resolution success: does the domain resolve at all?
- Lookup latency: how long does DNS take?
- Correct answers: A/AAAA/CNAME records are what you expect
- Propagation / consistency: do different probe locations get the same result?
- TTL behavior: are records expiring or changing unexpectedly?
- NXDOMAIN / SERVFAIL detection: did a bad record or DNS outage break resolution?
For CDN
Use synthetic checks to validate:
- Availability: does the content return 200/expected status?
- Latency / TTFB: is the edge responding quickly?
- Edge correctness: headers and content match expected cache behavior
- Cache hit/miss behavior: is the CDN caching as intended?
- Regional differences: are only some geographies slow or failing?
- Failover behavior: if an origin or edge goes down, does traffic route correctly?
Common synthetic check types
1) DNS lookup checks
Run periodic lookups for:
AAAAACNAMENSMXif relevant
Track:
- response time
- returned IPs
- response code
- differences by region/resolver
Example:
- From 5–10 probe regions, query
www.example.com - Alert if:
- resolution fails in any region
- the answer differs from the expected CDN IP range
- lookup time exceeds a threshold
2) HTTP/HTTPS endpoint checks
These test the user-facing site through the CDN:
- GET
/ - GET a static asset like
/logo.png - GET a cacheable file
- GET a known dynamic endpoint if you want to test origin routing
Track:
- HTTP status
- total time
- DNS time / connect time / TLS time / TTFB if available
- response body checksum or specific text
- headers such as:
AgeX-CacheViaServer- CDN-specific headers
3) Multi-location synthetic tests
This is important for CDN/DNS because issues are often regional. Use probes from:
- North America
- Europe
- Asia-Pacific
- South America
- one or more cloud regions if possible
This helps detect:
- DNS propagation delays
- CDN edge routing issues
- POP-specific outages
- ISP-specific issues
What to look for
Signs of DNS trouble
- Intermittent
SERVFAIL - Slow or inconsistent resolution
- Some locations resolving to old IPs
- DNSSEC validation failures
- CNAME chain problems
- Inconsistent answers across resolvers
Signs of CDN trouble
- High latency from a subset of regions
- Unexpected cache misses
- 4xx/5xx responses only at the edge
- Origin fetches spiking
- Wrong content or stale content being served
- TLS handshake failures at specific edge locations
Best practices
Use a baseline
Record normal behavior first:
- expected DNS answers
- expected response times
- expected headers
- expected content hash
Then alert on deviation rather than absolute values alone.
Test both resolvers and end-to-end paths
A DNS-only check might say the name resolves, but an HTTP synthetic test can reveal that the CDN edge is broken. Use both.
Monitor multiple record types
For example:
www.example.com→CNAMEto CDN- CDN host →
A/AAAA - apex records if you use ALIAS/ANAME or flattened DNS
Separate “availability” from “quality”
Alert on:
- hard failures: no response, wrong status, resolution failure
- soft failures: latency degradation, cache miss increase, header changes
Use canary endpoints
Have a dedicated test path such as:
/synthetic/health/cdn-check.txt
This avoids noisy production behavior and lets you validate specific caching or routing behavior.
Correlate with DNS and CDN logs
Synthetic monitoring tells you what users experienced; logs tell you why. Correlate:
- resolver logs
- CDN logs
- origin logs
- BGP/ISP incidents if relevant
Example monitoring setup
DNS synthetic check
Every 1 minute from 6 regions:
- Query
www.example.com - Validate it returns the expected CNAME
- Validate final A/AAAA IPs are in the expected CDN ranges
- Alert if:
- any region fails 3 times in a row
- lookup time > 200 ms for 5 minutes
- different regions resolve to materially different targets
CDN synthetic check
Every 1 minute from 6 regions:
- Request
https://www.example.com/cdn-check.txt - Check:
- status = 200
- body = expected content
Age> 0 after warm-upX-Cacheindicates HIT most of the time
- Alert if:
- 5xx rate rises
- TTFB spikes in one or more regions
- cache hit ratio drops suddenly
Useful metrics
For DNS:
- lookup success rate
- DNS latency
- resolver consistency
- SERVFAIL/NXDOMAIN rate
For CDN:
- HTTP success rate
- TTFB
- full load time
- cache hit ratio
- origin fetch rate
- regional performance spread
Tools you can use
Depending on your stack:
- Pingdom / UptimeRobot / Datadog Synthetics / New Relic Synthetics
- Catchpoint / ThousandEyes for deep network/DNS visibility
- Cloud provider synthetic probes
- Custom scripts using
dig,nslookup,curl, or browser-based test runners
Quick recommendation
If you’re starting out, set up:
- A DNS lookup monitor for your main hostname from multiple regions
- An HTTPS endpoint monitor for a cacheable path
- Alerts on:
- resolution failures
- elevated latency
- region-specific failures
- unexpected headers/content
If you want, I can give you:
- a step-by-step setup for a specific tool,
- a Prometheus/Grafana approach,
- or a custom script for DNS/CDN synthetic checks.