Linux uname Command
The Linux uname (short for unix name) command is used to display operating system information, such as the kernel version, host name, processor type, and so on.
uname can display information about the computer and the operating system.
Syntax
uname [-amnrsv][--help][--version]
Parameter Description:
- -a or --all Display all information, including the kernel name, host name, operating system version, processor type, and hardware architecture.
- -m or --machine Display the processor type.
- -n or --nodename Display the host name.
- -r or --release Display the kernel release version.
- -s or --sysname Display the operating system name.
- -v Display the operating system version.
- --help Display help.
- --version Display version information.
- -p Display the processor type (same as the -m option).
Example
Display system information:
# uname -a
Linux iZbp19byk2t6khuqj437q6Z 4.11.0-14-generic #20~16.04.1-Ubuntu SMP Wed Aug 9 09:06:22 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Display the computer type:
# uname -m
x86_64
Display the computer name:
# uname -n
runoob-linux
Display the operating system release number:
# uname -r
4.11.0-14-generic
Display the operating system name:
# uname -s
Linux
Display the system version and time:
# uname -v
#20~16.04.1-Ubuntu SMP Wed Aug 9 09:06:22 UTC 2017
Linux Command Reference