You are helping the user monitor live system resource usage (CPU, RAM, disk I/O, network).
Monitor live system resources (CPU, RAM, disk I/O, network) to identify bottlenecks and resource hogs. Use when troubleshooting performance issues or checking system health.
/plugin marketplace add danielrosehill/linux-desktop-plugin/plugin install lan-manager@danielrosehillYou are helping the user monitor live system resource usage (CPU, RAM, disk I/O, network).
Quick resource overview:
# System overview
top -b -n 1 | head -20
# Better overview with htop (if installed)
htop
# Modern alternative: btop
btop
CPU monitoring:
# CPU usage summary
mpstat 1 5 # 5 samples, 1 second interval
# Per-core usage
mpstat -P ALL 1 5
# Top CPU consumers
ps aux --sort=-%cpu | head -10
# CPU frequency and temperature
watch -n 1 "grep MHz /proc/cpuinfo | head -20 && sensors"
Memory monitoring:
# Memory usage
free -h
# Detailed memory info
cat /proc/meminfo
# Top memory consumers
ps aux --sort=-%mem | head -10
# Memory usage by process
smem -tk # If smem is installed
# Watch memory usage
watch -n 1 free -h
Disk I/O monitoring:
# I/O statistics
iostat -x 1 5
# Disk usage by device
iotop -o # Only show active I/O
# Per-process I/O
iotop -P
# Watch disk I/O
watch -n 1 "iostat -x | grep -E 'Device|sd|nvme'"
Network monitoring:
# Network interface statistics
ifstat 1 5
# Bandwidth per interface
bmon
# Network speed
iftop
# Connection summary
ss -s
# Active connections
nethogs
Combined system monitoring:
# All-in-one monitoring
glances
# Custom dashboard
watch -n 1 '
echo "=== CPU ==="
top -b -n 1 | head -5 | tail -2
echo ""
echo "=== Memory ==="
free -h | grep -E "Mem|Swap"
echo ""
echo "=== Disk I/O ==="
iostat -x 1 1 | grep -E "Device|sd|nvme" | head -5
echo ""
echo "=== Network ==="
ifstat 1 1 | tail -1
'
GPU monitoring (AMD):
# AMD GPU usage
radeontop
# GPU sensors
watch -n 1 "rocm-smi"
# Detailed GPU info
watch -n 1 "rocm-smi --showuse --showmemuse --showtemp"
Process tree with resource usage:
# Process tree
pstree -p
# Resource-aware process tree
ps auxf
# Find resource hogs
ps -eo pid,ppid,cmd,%mem,%cpu --sort=-%cpu | head -20
System load monitoring:
# Load average
uptime
# Load over time
watch -n 1 "uptime && cat /proc/loadavg"
# Who's causing load
tload -d 1
Create monitoring script:
cat > /tmp/system-monitor.sh << 'EOF'
#!/bin/bash
echo "System Resource Monitor - $(date)"
echo "========================================"
echo ""
echo "CPU Usage:"
mpstat 1 1 | tail -1
echo ""
echo "Memory:"
free -h | grep -E "Mem|Swap"
echo ""
echo "Load Average:"
uptime
echo ""
echo "Top 5 CPU Processes:"
ps aux --sort=-%cpu | head -6 | tail -5
echo ""
echo "Top 5 Memory Processes:"
ps aux --sort=-%mem | head -6 | tail -5
echo ""
echo "Disk Usage:"
df -h / /home
echo ""
echo "Disk I/O:"
iostat -x 1 1 | grep -E "sd|nvme"
EOF
chmod +x /tmp/system-monitor.sh
/tmp/system-monitor.sh
Provide snapshot of:
Flag any concerning patterns:
# Install commonly needed tools
sudo apt install -y \
htop \
btop \
iotop \
iftop \
nethogs \
glances \
sysstat \
bmon \
radeontop
High CPU:
top or htopkill -15 PIDHigh Memory:
ps aux --sort=-%memsudo sync && sudo sysctl -w vm.drop_caches=3High Disk I/O:
iotop -o/check-disk-errorsHigh Network:
nethogs or iftopss -tunap to see connectionsglances provides best all-in-one viewbtop is modern, colorful alternative to htopsystemd-cgtop for cgroup resource usage