Your memory's wise advisor - Intelligent RAM usage visualizer for Arch Linux
ramwise is a terminal-based RAM usage visualizer that goes beyond basic memory monitoring. It provides deep memory introspection, intelligent leak detection, and beautiful visualization all in a lightweight TUI application.
- Deep Memory Introspection - See RSS, PSS, USS, shared/private breakdown per process
- Intelligent Insights - Rule-based analysis detects memory leaks, hogs, and anomalies
- Beautiful TUI - Modern interface with graphs, colors, and intuitive navigation
- Minimal Footprint - Written in Rust for maximum efficiency
- Real-time Updates - Live monitoring with configurable refresh rate
- Process Control - Stop (
SIGTERM) or kill (SIGKILL) selected processes directly from the TUI
The collector exposes a versioned ExportSnapshot contract for integrations and
future export formats. It uses wall-clock Unix milliseconds, explicit byte/count
units, collector metadata, and capability markers. Runtime-only monotonic
Instant values are intentionally not serialized; unavailable features remain
explicit in the exported capability map.
# Clone the repository
git clone https://github.com/Duckaet/ramwise
cd ramwise
# Build release binary
cargo build --release
# Install (optional)
sudo cp target/release/ramwise /usr/local/bin/# Run with default settings (1s refresh, 1MB minimum RSS)
ramwise
# Custom refresh interval (500ms)
ramwise --interval 500
# Show all processes (including small ones)
ramwise --min-rss 0
# Disable smaps collection (faster but less detailed)
ramwise --no-smaps
# Enable debug logging
ramwise --debug
# Use light mode
ramwise -t lightCapture one JSON snapshot to stdout, or write JSON/CSV files without starting the TUI:
# Machine-readable JSON on stdout
ramwise --once > snapshot.json
# Refuse to overwrite existing files
ramwise --export-json snapshot.json --export-csv snapshot.csv
# Replace existing files explicitly
ramwise --export-json snapshot.json --force
# Include per-mapping details in the CSV and timestamp the filename
ramwise --export-csv capture.csv --export-details --export-timestamped
# Stream CSV to stdout
ramwise --export-csv -Export failures and diagnostics are written to stderr; JSON and CSV payloads
remain on stdout only when - is used.
| Key | Action |
|---|---|
j/k or ↑/↓ |
Navigate process list |
Tab |
Cycle focus between panels |
Shift+Tab |
Reverse cycle focus |
s |
Cycle sort mode (RSS/PSS/Private/Name/PID) |
g |
Go to top of list |
G |
Go to bottom of list |
x |
Send SIGTERM to selected process |
X |
Confirm and send SIGKILL to selected process |
? |
Toggle help overlay |
q |
Quit |
Notes:
SIGKILLrequires confirmation in-app (Enterconfirm,Esccancel).- Process control follows OS permissions; root-owned processes may return permission errors.
ramwise now supports direct process signaling from the process list:
- Select a process with
j/kor↑/↓. - Press
xto sendSIGTERM(graceful stop). - Press
Xto open kill confirmation, then:Enterto sendSIGKILLEscto cancel
Action results are shown as in-app status messages (success, warning, or error).
ramwise includes built-in themes selectable via --theme or -t:
# Launch with dark theme (default)
ramwise -t dark
# Launch with light theme (Gruvbox Light)
ramwise -t lightCustom themes can be added to src/ui/theme.rs and registered in App::new (src/app.rs).
Layout dimensions and panel splits can be customized in src/ui/layout.rs (Layout::new):
header_height: Height of the top status bar.center_height: Minimum height of the main process/detail panels.bottom_height: Height of the insights panel.left_width_percent: Width percentage allocated to the process list.side_vertical_split_percent: Height percentage allocated to process details vs memory graph.invert_horizontal_split: Swap process list and side panels.invert_side_vertical_split: Swap detail view and trend graph.put_insights_on_top: Place the insights panel below the header instead of at the bottom.
ramwise includes intelligent analysis rules:
| Rule | Severity | Description |
|---|---|---|
| Memory Leak Detector | Warning/Critical | Detects consistent RSS growth patterns |
| Memory Hog | Warning | Flags processes using >30% of total RAM |
| Sudden Spike | Warning | Alerts on rapid memory increases (>100MB in 10s) |
| OOM Risk | Critical | Warns when system is at risk of OOM |
| Swap Pressure | Warning | Detects excessive swap usage |
| Fragmentation | Info | Identifies high VSS/RSS ratios |
| Cache Info | Info | Explains high page cache usage |
ramwise/
├── src/
│ ├── main.rs # Entry point, async event loop
│ ├── app.rs # Application state
│ ├── collector/ # Memory data collection from /proc
│ ├── analyzer/ # Rule engine and insights
│ ├── history/ # Time-series data buffer
│ ├── ui/ # Ratatui TUI components
│ └── utils/ # Formatting utilities
- Linux kernel 2.6.28+ (for
/proc/[pid]/smaps_rollup) - Terminal with color support
Contributions are welcome! Please feel free to submit a Pull Request.
MIT License - see LICENSE for details.
Built with:
