Having useful commands to use as an aid in troubleshooting, checking system resources etc at hand can be extremely useful. As such, this page is a place to find useful commands for managing your system.
top - overview Check
dmesg -T - Check Kernel errors with timestamp
vmstat 3 - Check system stats refreshed every 3 seconds
mpstat -P ALL 3 - Check CPU usage across all available cores every 3 seconds
pidstat 3 - Check resource usage of processes every 3 seconds
iostat -xz 3 - Check disk IO every 3 seconds
iotop - Check disk IO in top fashion
sar -n DEV 3 - Check network IO
sar -n TCP 3 - Check TCP stats and network saturation
strace -tp $(pgrep PROCESS) 2>&1 | head - Trace performance errors with timestamp of processes
slabtop - Check in depth memory usage, paging, swapping
free -m - Memory statistics
uptime - Check system uptime since last reboot and load averages
w - Check load averages and logged in users
ss - Socket Statistics replaced netstat
netstat - Check established, listening and dropped connections to ports
lsof -i :n - List open files establised or listening on a chosen port represented by n
lsof -i tcp -a -u root - Check all TCP sockets opened by a user
lsof -p <PID> - Check all open files by PID
lsof -nP | grep deleted - Find large files still open but deleted by the system
find /proc/*/fd | grep deleted - Find large files still open but deleted by the system