Lightweight Infrastructure Monitoring & Alerting System built with Bash.
InfraPulse is a lightweight monitoring agent designed to observe and report the health of multiple infrastructure nodes (Linux / VMware ESXi). It collects system performance metrics such as CPU load, memory usage, disk usage, and host availability, then stores the results in both human-readable logs and structured JSON format for automation and future cloud integration.
InfraPulse continuously monitors remote hosts over the network and provides:
- Host availability checking (UP/DOWN via ping)
- CPU load monitoring
- Memory usage collection
- Disk usage monitoring
- Health score calculation
It generates two types of outputs:
- Human-readable logs for manual inspection
- JSON output for machine processing, automation, and APIs
It also includes a basic alerting system and supports automation via cron jobs.
- Multi-host monitoring (Linux / ESXi)
- Ping-based host availability check
- CPU / RAM / Disk usage collection via SSH
- Structured logging system (monitor.log)
- JSON output for automation (output.json)
- Alerting system (alerts.log)
- Health score calculation
- Cron-based scheduling support
The monitoring workflow is as follows:
- Ping target hosts
- Connect via SSH
- Collect system metrics (CPU, RAM, Disk)
- Write human-readable logs
- Generate JSON structured output
- Trigger alerts if thresholds are violated
InfraPulse/
├── scripts/
│ └── monitor.sh
├── logs/
│ ├── monitor.log
│ ├── alerts.log
│ └── output.json
├── .gitignore
└── README.md
git clone <repo-url>
cd InfraPulse
chmod +x scripts/monitor.shRun manually:
./scripts/monitor.shView logs:
cat logs/monitor.log
tail -f logs/monitor.logView JSON output:
cat logs/output.jsonInfraPulse can be scheduled using cron for continuous monitoring.
Edit crontab:
crontab -eAdd the following line:
*/5 * * * * /opt/infra-pulse/scripts/monitor.sh >> /dev/null 2>&1This runs the monitoring system every 5 minutes automatically.
InfraPulse supports basic alerting for critical conditions.
Example email alert using mailx:
echo "Host is DOWN" | mail -s "InfraPulse Alert" admin@example.comAlerts can be triggered for:
- Host unreachable (DOWN)
- High disk usage
- Missing or failed metric collection
[INFO] 192.168.4.10 is UP
[CPU LOAD] 0.01, 0.02, 0.00
[MEMORY] 4189040640 bytes
[DISK USAGE] 16%
{
"host": "192.168.4.10",
"status": "UP",
"cpu": "0.01, 0.02, 0.00",
"memory": "4189040640",
"disk": "16%"
}- Telegram alert integration
- Web dashboard (HTML / React)
- Prometheus exporter
- Grafana visualization
- Cloud-native deployment (AWS / Azure / GCP)
- REST API for monitoring data
- Kubernetes monitoring support
- Bash
- SSH
- VMware ESXi CLI
- Linux System Utilities
- Cron
- Python
InfraPulse – Infrastructure Monitoring & Observability Lab Project