linux get distro command line code example Example 1: get linux distro from terminal dmesg | head -1 Example 2: linux get distro cat /etc/os-release