linux show hostname code example Example 1: linux show version cat /etc/os-release Example 2: how to get hostname on linux $ hostnamectl