LINUX ESSENTIALS CHEATSHEET ========================== 1. SYSTEM & HARDWARE uname -a Kernel and architecture info lsb_release -a Distribution version uptime System uptime and load average free -h RAM and swap usage df -h Disk space usage by mountpoint du -sh * Size of folders in current directory 2. PROCESSES & LOGS top / htop Interactive process viewer ps aux | grep Find running process kill -15 Graceful stop (SIGTERM) journalctl -xe Recent system errors journalctl -u -f Follow logs of a systemd service 3. FILES & PERMISSIONS chmod 644 file rw-r--r-- (standard file) chmod 755 script.sh rwxr-xr-x (executable / directory) chown user:group file Change owner and group tar -czf out.tar.gz dir Create compressed archive tar -xzf out.tar.gz Extract compressed archive find /var/log -name "*.log" -mtime +7 Find logs older than 7 days