A powerful, configurable system monitoring tool built in Rust that provides real-time insights into your system's performance.
- Real-time Monitoring: CPU, memory, disk, and process monitoring
- Color-coded Progress Bars: Visual representation of system usage
- Configurable Thresholds: Custom warning and critical levels
- Alert System: Automatic alerts with logging when thresholds are exceeded
- Multiple Display Modes: Continuous monitoring, one-time summary, or single run
- Cross-platform: Works on Linux, macOS, and Windows
- Professional Output: Clean, organized display with timestamps
cargo install system-monitor
brew install system-monitor
choco install system-monitor
git clone https://github.com/yourusername/system-monitor.git
cd system-monitor
cargo install --path .
Download the latest release for your platform from GitHub Releases.
# Run continuous monitoring
system-monitor
# One-time system summary
system-monitor summary
# Generate configuration file
system-monitor generate-config
# Show help
system-monitor --help
Command | Description |
---|---|
system-monitor |
Default continuous monitoring (30-second intervals) |
system-monitor summary |
One-time system summary |
system-monitor generate-config |
Generate configuration file |
system-monitor monitor |
Explicit monitor mode |
system-monitor --once |
Run once and exit |
system-monitor --help |
Show help information |
system-monitor --version |
Show version information |
Generate a configuration file to customize thresholds and display options:
system-monitor generate-config
This creates a config.toml
file:
[general]
refresh_interval = 30
log_alerts = true
log_file = "system_monitor.log"
[display]
show_progress_bars = true
use_colors = true
show_per_core_cpu = true
max_processes_to_display = 10
[thresholds]
cpu_warning = 70.0
cpu_critical = 90.0
memory_warning = 70.0
memory_critical = 90.0
disk_warning = 70.0
disk_critical = 90.0
swap_warning = 70.0
swap_critical = 90.0
================================================
System Monitor - 2025-08-08 15:30:45
================================================
CPU INFORMATION
Overall Usage: [####----------------] 21.5%
Per Core:
Core 0: [########------------] 40.9%
Core 1: [#######-------------] 38.1%
Core 2: [######--------------] 33.5%
Core 3: [######--------------] 30.5%
MEMORY INFORMATION
RAM Usage: [################----] 80.2%
Total: 8.0 GB
Used: 6.4 GB
Available: 1.6 GB
DISK INFORMATION
Mount: / [##############------] 73.3%
Total: 460.4 GB | Used: 337.6 GB | Free: 122.9 GB
TOP PROCESSES
PID NAME CPU% MEMORY
--------------------------------------------------
1234 chrome 15.2% 512.3MB
5678 firefox 8.1% 256.1MB
SYSTEM INFORMATION
OS: Darwin
Hostname: MacBookAir
Uptime: 1647h 1m
Load Avg: 2.56, 3.57, 3.71
Press Ctrl+C to exit...
Color | Meaning | Usage Range |
---|---|---|
Green | Normal | Below warning threshold |
Yellow | Warning | Warning to critical threshold |
Red | Critical | Above critical threshold |
refresh_interval
: Update frequency in secondslog_alerts
: Enable/disable alert logginglog_file
: Path to log file
show_progress_bars
: Visual progress barsuse_colors
: Colored outputshow_per_core_cpu
: Individual CPU core displaymax_processes_to_display
: Number of top processes
Customize warning and critical levels for:
- CPU usage
- Memory usage
- Disk usage
- Swap usage
When thresholds are exceeded, alerts are:
- Logged to console with timestamps
- Written to log file (if enabled)
- Can trigger desktop notifications (future feature)
- Rust 1.70 or later
- Cargo (comes with Rust)
git clone https://github.com/yourusername/system-monitor.git
cd system-monitor
cargo build --release
cargo test
cargo clippy
cargo fmt -- --check
- Low Resource Usage: Minimal CPU and memory footprint
- Fast Startup: Sub-second initialization
- Efficient Updates: Optimized refresh cycles
- Cross-platform: Native performance on all platforms
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Network bandwidth monitoring
- Docker container monitoring
- Web dashboard interface
- Email alert notifications
- Historical data logging
- Plugin system for custom metrics
- JSON/CSV export functionality
- Interactive terminal UI mode
- Built with sysinfo for cross-platform system information
- Inspired by traditional monitoring tools like
htop
andtop
- Thanks to the Rust community for excellent crates and documentation