uname: Print all information about the current operating system
August 9th, 2024 1:01 PM Mr. Q Categories: Command
uname -a
All information: Displays all available system information.
Command: uname -a
Example Output:
$ uname -a
Linux hostname 5.15.0-76-generic #83-Ubuntu SMP Fri Jul 7 16:04:04 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
The uname
command provides information about the system on which it is run. The -a
option prints all available system information, including the kernel name, version, and architecture, as well as the system’s hostname.
Linux
: Kernel name, which is typically “Linux” on a Linux-based system.hostname
: The system’s hostname.5.15.0-76-generic
: Kernel version, which includes the version number, type, and patch level.#83-Ubuntu SMP Fri Jul 7 16:04:04 UTC 2023
: Additional version information, including the build number, distribution (Ubuntu), SMP (Symmetric multiprocessing kernel), and build date.x86_64
: Processor architecture, indicating a 64-bit system.GNU/Linux
: The operating system type.
uname -s
Kernel name: Displays the name of the kernel.
Command: uname -s
Example Output:
$ uname -s
Linux
uname . -n
Network node hostname: Displays the network node hostname of the system.
Command: uname -n
Example Output:
$ uname -n
hostname
uname -r
Kernel release: Displays the release number of the kernel.
Command: uname -r
Example Output:
$ uname -r
5.15.0-76-generic
uname -v
Kernel version: Displays the version of the kernel, including the build number and date.
Command: uname -v
Example Output:
$ uname -v
#83-Ubuntu SMP Fri Jul 7 16:04:04 UTC 2023
uname -m
Machine hardware name: Displays the hardware architecture of the machine.
Command: uname -m
Example Output:
$ uname -m
x86_64
uname -p
Processor type: Displays the processor type, if known.
Command: uname -p
Example Output:
$ uname -p
x86_64
uname -i
Hardware platform: Displays the platform of the hardware, if known.
Command: uname -i
Example Output:
$ uname -i
x86_64
uname -o
Operating system: Displays the name of the operating system.
Command: uname -o
Example Output:
$ uname -o
GNU/Linux
Note: The uname
command provides a quick and effective way to gather key details about the system, which can be useful for system administration, debugging, and documentation purposes.