Set up real-time monitoring, alerting rules, log aggregation, and uptime checks for your infrastructure.
Monitoring is the foundation of reliable infrastructure. Without visibility into your servers, you are flying blind. Rackline includes built-in monitoring with real-time metrics, customizable alerts, centralized log aggregation, and uptime monitoring. This tutorial covers setting up comprehensive observability for your applications.
The Rackline monitoring dashboard displays real-time and historical metrics for all your resources. Key metrics include CPU utilization, memory usage, disk I/O, network bandwidth, and HTTP response times. Metrics are retained for 30 days on all plans and 90 days on Professional plans.
# View current metrics for a droplet
rackline monitor my-first-droplet
# View metrics for a specific time range
rackline monitor my-first-droplet \
--from "2026-03-01T00:00:00Z" \
--to "2026-03-19T23:59:59Z"
# Export metrics as CSV
rackline monitor my-first-droplet --format csv > metrics.csvCreate alert rules that notify you when metrics exceed thresholds. Rackline supports email, Slack, PagerDuty, and webhook alert channels. Configure escalation policies to ensure critical alerts are never missed.
# Add a Slack notification channel
rackline monitor channels add slack \
--name ops-alerts \
--webhook-url "https://hooks.slack.com/services/xxx/yyy/zzz"
# Create CPU alert
rackline monitor alerts create \
--resource my-first-droplet \
--metric cpu \
--condition "above 80% for 5 minutes" \
--channel ops-alerts \
--severity warning
# Create memory alert
rackline monitor alerts create \
--resource my-first-droplet \
--metric memory \
--condition "above 90% for 2 minutes" \
--channel ops-alerts \
--severity critical
# Create disk space alert
rackline monitor alerts create \
--resource my-first-droplet \
--metric disk \
--condition "above 85%" \
--channel ops-alerts \
--severity warningPro Tip
Avoid alert fatigue by setting appropriate thresholds and durations. A CPU spike to 95% for 10 seconds is normal during deployments, but sustained 80%+ for 5 minutes warrants investigation.
Rackline centralizes logs from all your resources into a searchable log viewer. Application logs, system logs, and deployment logs are automatically collected. Use structured logging in your application for better searchability.
# Stream logs in real-time
rackline logs --follow --resource my-first-droplet
# Search logs with filters
rackline logs search \
--query "error" \
--from "1h ago" \
--resource my-first-droplet
# Filter by severity
rackline logs search \
--level error \
--from "24h ago"
# Export logs
rackline logs export \
--from "2026-03-18" \
--to "2026-03-19" \
--format json > logs.jsonUptime monitors check your application endpoints from multiple global locations every 60 seconds. If your application goes down, you are alerted immediately and Rackline logs the downtime event for SLA tracking.
# Create an uptime monitor
rackline monitor uptime create \
--url "https://example.com/health" \
--interval 60s \
--regions us-east,eu-west,ap-southeast \
--channel ops-alerts
# View uptime history
rackline monitor uptime status --url "https://example.com/health"
# Generate an uptime report
rackline monitor uptime report \
--from "2026-03-01" \
--to "2026-03-19"Pro Tip
Monitor your health check endpoint rather than your homepage. A 200 response from /health that also verifies database connectivity gives you confidence that the entire stack is operational.
Your infrastructure is now fully observable with real-time metrics, intelligent alerts, centralized logging, and uptime monitoring. Proactive monitoring catches issues before they impact users and provides the data you need for capacity planning and performance optimization.
Next tutorial