Linux uuname Command
The Linux uname command is used to display information about the current system.
uname is the abbreviation for "UNIX name", providing a quick way to view system information.
The uname command can provide the system's name, version, hardware architecture, and other information, helping users quickly understand the configuration of the current operating system.
Syntax
uname [选项]
The output and detailed information of the uname command vary depending on the different options.
Parameter Description:
-a, --all: Displays all available information, including kernel name, node name, kernel release, machine type, processor type, hardware platform, and operating system.-s, --kernel-name: Displays the kernel name.-n, --nodename: Displays the network node name.-r, --kernel-release: Displays the kernel release version.-v, --kernel-version: Displays the kernel version.-m, --machine: Displays the computer's hardware architecture.-p, --processor: Displays the processor type.-i, --hardware-platform: Displays the hardware platform.-o, --operating-system: Displays the operating system name.
Examples
1. Display all system information:
uname -a
Sample output:
Linux myhostname 5.8.0-53-generic #60~18.04.1-Ubuntu SMP Tue Apr 13 20:37:32 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Explanation:
Linux: Operating system namemyhostname: Hostname5.8.0-53-generic: Kernel version#60~18.04.1-Ubuntu SMP Tue Apr 13 20:37:32 UTC 2021: Kernel compilation information and timex86_64: Machine architectureGNU/Linux: Operating system type
2. Check the kernel version:
uname -r
Sample output:
5.8.0-53-generic
3. Check the operating system name:
uname -s
Sample output:
Linux
4. Check the hardware architecture:
uname -m
Sample output:
x86_64Other Extensions
Linux Command Collection