This is a shell script (written for /bin/sh, typically run on Linux) designed to run automated, basic health and performance diagnostics on a machine. It acts as an automated morning health checklist for system administrators or developers.
date command.127.0.0.1 4 times (ping -c 4)./dev/null to keep the console output clean.$? (the exit code of the ping command). If 0 (success), it reports that loopback is reachable. This tests whether the system's internal network stack/adapter is functioning locally.1.1.1.1 (Cloudflare’s public DNS server) 4 times.df -h / to show available and used disk space on the root (/) filesystem in human-readable units (GB/MB).uptime to display how long the server has been running, logged-in user counts, and system load averages over the last 1, 5, and 15 minutes.free -h to display total, used, free, and available RAM and Swap memory in human-readable units.ps sorted by %cpu in descending order, then extracts the top 6 lines (1 header line + top 5 processes) using head -n 6.ssh and cron).systemctl is-active --quiet <service> to check if the background service is running, printing ACTIVE or INACTIVE depending on the result.morning_check.sh.chmod +x morning_check.sh
./morning_check.sh