Datadog Documentation
Complete guides for Datadog agent setup, configuration, and network connectivity testing with enterprise-grade monitoring.
Datadog Endpoints Reference​
US Datacenter (Default)​
- API:
api.datadoghq.com - Traces/APM:
trace.datadoghq.com - Logs Intake:
http-intake.logs.datadoghq.com - RUM:
rum.datadoghq.com
EU Datacenter​
- API:
api.datadoghq.eu - Traces/APM:
trace.datadoghq.eu - Logs Intake:
http-intake.logs.datadoghq.eu - RUM:
rum.datadoghq.eu
Key Datadog Agent Configuration​
Basic Configuration​
api_key: your_api_key_here
site: datadoghq.com # or datadoghq.eu
hostname: your-server-name
tags:
- env:production
- service:myapp
- team:devops
logs_enabled: true
apm_config:
enabled: true
apm_dd_url: https://trace.datadoghq.com
Proxy Configuration​
proxy:
https: "http://proxy-server:8080"
http: "http://proxy-server:8080"
no_proxy:
- "localhost"
- "127.0.0.1"
Common Datadog Operations​
Agent Management​
sudo systemctl start datadog-agent # Start agent
sudo systemctl stop datadog-agent # Stop agent
sudo systemctl restart datadog-agent # Restart agent
sudo systemctl status datadog-agent # Check status
sudo systemctl enable datadog-agent # Enable auto-start
Testing & Verification​
sudo datadog-agent status # Show agent status
sudo datadog-agent diagnose # Run diagnostics
sudo datadog-agent configcheck # Validate config
sudo datadog-agent check nginx # Test integration
Logging​
sudo tail -f /var/log/datadog/agent.log # Follow logs
sudo grep -i error /var/log/datadog/agent.log # Find errors
sudo journalctl -u datadog-agent -f # System logs
Connectivity Testing​
# Test API connectivity
curl -s https://api.datadoghq.com/api/v1/validate \
-H "DD-API-KEY: $DD_API_KEY"
# Test through proxy
curl -x http://proxy-server:8080 \
https://api.datadoghq.com/api/v1/validate
# Check port connectivity
nc -zv api.datadoghq.com 443
Command Statistics​
- Total Datadog Commands: 75+
- Setup Commands: 25+
- Proxy Testing Commands: 25+
- Monitoring Commands: 25+
Quick Troubleshooting​
Agent Not Starting​
sudo datadog-agent configcheck # Check config syntax
sudo journalctl -u datadog-agent -n 50 # View recent errors
No Metrics Sending​
sudo grep "api_key" /etc/datadog-agent/datadog.yaml
curl -s https://api.datadoghq.com -H "DD-API-KEY: test"
Proxy Issues​
sudo tail -50 /var/log/datadog/agent.log | grep -i proxy
curl -v -x http://proxy-server:8080 https://api.datadoghq.com
Environment Variables​
# Essential variables
DD_API_KEY="your_api_key"
DD_SITE="datadoghq.com" # or datadoghq.eu
DD_ENV="production"
DD_SERVICE="myapp"
DD_VERSION="1.0.0"
# Proxy configuration
HTTP_PROXY="http://proxy-server:8080"
HTTPS_PROXY="http://proxy-server:8080"
NO_PROXY="localhost,127.0.0.1"
Best Practices​
Best Practices
- Secure API Keys: Store in environment variables, not in files
- Use HTTPS: Always communicate with Datadog over HTTPS
- Monitor Agent: Set up monitoring for the monitoring agent itself
- Test Before Production: Always test proxy and connectivity first
- Keep Logs: Enable and monitor agent logs for troubleshooting
- Tag Resources: Use consistent tags for organization
- Review Integrations: Only enable needed integrations
- Update Regularly: Keep agent updated for security patches
- Document Configuration: Keep proxy and endpoint settings documented
- Plan Failover: Have backup endpoints in your configuration
Documentation Sections​
- Dynatrace to Datadog Migration - Complete 11-step migration guide
- Datadog Proxy Testing - Network proxy diagnostics
- Agent Proxy Configuration - Proxy setup guide
- OpenJDK Monitoring - Java application monitoring
- SSL Certificate Configuration - SSL setup guide
Related Sections​
- Linux Commands: Linux Documentation
- Services: Service Management