Explore package management, identify distributions, manage software repositories, and practice the skills that keep Linux systems updated and functional.
cat /etc/os-release — this works on virtually every modern Linuxlsb_release -a 2>/dev/nullcat /etc/debian_version 2>/dev/null || cat /etc/redhat-release 2>/dev/null || cat /etc/arch-release 2>/dev/nulluname -r — the kernel version often reveals distribution clueswhich apt dpkg dnf yum pacman 2>/dev/nullsudo apt update — always do this before installing anythingapt search tree — note how many packages matchapt show tree — check description, size, dependenciessudo apt install tree -ywhich tree && tree --versiontree /etc/ssh/dpkg -L tree (list all files installed by the package)sudo apt remove tree (config files kept) or sudo apt purge tree (removes everything)sudo apt autoremovecat /etc/apt/sources.list — understand the components (main, universe, restricted, multiverse)ls -la /etc/apt/sources.list.d/apt-cache policyapt-cache policy nginx (even if not installed, shows available versions and sources)apt-cache stats | grep "Total package"dpkg-query -W --showformat='${Installed-Size}\t${Package}\n' | sort -rn | head -20dpkg -S /usr/bin/sshnano ~/distro-analysis.txt