• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer

KaliTut

Kali Linux tutorial and Linux Tips

  • Home
  • Raspberry Pi
  • Privacy Policy
  • About us
  • Affiliate disclaimer

uname command in Linux

August 8, 2024 by Walid Salame

The uname command in Linux is used to display system information. It provides details about the operating system, kernel version, and other system-specific data. Let’s break down its functionality and provide some examples.

uname command in Linux
uname [OPTION]...

Options
Here are some commonly used options with uname:

Short optionsLong optionsmeaning
-a–allDisplays the kernel name (-s), hostname (-n), kernel release number (-r), kernel version (-v), hardware name (-m), CPU (-p, omitted if unknown), hardware platform (-i, omitted if unknown), and OS name (-o), in that order.
-s–kernel-nameShow kernel name (default)
-n–nodenameShow hostname (network node)
-r–kernel-releasePrint the kernel release number
-v–kernel-versionShow kernel version
-m–machineShow hardware name (e.g. x86_64)
-p–processorShow CPU type (or “unknown” if unknown)
-i–hardware-platformShow the hardware platform (or “unknown” if unknown)
-o–operating-systemShow the name of the OS

Examples

Print the Kernel Name:

uname -s
uname -s

Print the Network Node Hostname:

uname -n
Output
localhost

Print the Kernel Release:

uname -r
Output:
6.6.9-amd64

Print the Kernel Version:

uname -v
Output:
#1 SMP PREEMPT_DYNAMIC Kali 6.6.9-1kali1 (2024-01-08)

Print the Machine Hardware Name:

uname -m
Output:
x86_64

Print the Processor Type (might be unknown on some systems):

uname -p
Output:
x86_64

Print the Hardware Platform (might be unknown on some systems):

uname -i
Output:
x86_64

Print the Operating System:

uname -o
Output:
GNU/Linux

Print All System Information:

uname -a
Output:
Linux localhost 5.4.0-42-generic #46-Ubuntu SMP Fri Jul 10 00:24:02 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

Explanation of Output

  • Linux: The kernel name.
  • localhost: The network node hostname.
  • 5.4.0-42-generic: The kernel release version.
  • #46-Ubuntu SMP Fri Jul 10 00:24:02 UTC 2020: The kernel version, including build and compiler info.
  • x86_64: The machine hardware name, processor type, and hardware platform (all are the same in this example).
  • GNU/Linux: The operating system name.

Summary

The uname command is a versatile tool to quickly gather system information, particularly useful in scripting and system administration tasks. By using the appropriate options, you can specify exactly what information you need, or use -a to get a comprehensive overview of the system.

Post Views: 245

Filed Under: Linux Commands

Reader Interactions

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

Follow us

  • Facebook
  • Twitter
  • YouTube

Categories

  • algorithm
  • Android Ai coding
  • Android pentesting tools
  • Arduino
  • Artificial Intelligence
  • Books
  • ChatGPT Prompt
  • Darknet
  • database
  • General
  • Github Tools
  • Hacking
  • Kali Linux
  • Linux
  • Linux Commands
  • Network Administrator
  • Penetration Testing
  • Penetration Testing Tools
  • PowerShell
  • Raspberry Pi
  • resources
  • Review
  • Termux
  • Tutorials
  • Ubuntu
  • Uncategorized
  • Video Tutorials
  • vmware
  • WiFi Adapter
  • WiFi Pentesting
  • Wireless Router
  • Wireshark

Recent Posts

  • Transforming Photos with ChatGPT Prompt : A Cinematic Double Exposure in a Post-Apocalyptic World
  • Stryker Android App: Your Mobile Pentesting Powerhouse
  • Alfa awus036ach review
  • Alfa AWUS1900 for Wireless Penetration Testing
  • How to Run DeepSeek AI Locally on Kali Linux – Step-by-Step Guide

Footer

Kalitut

Kalitut.com goal is to share the knowledge for free, help you find the best tools on the web and provides tutorials

Find us on social media

  • Facebook
  • Pinterest
  • Reddit
  • Twitter
  • YouTube

Copyright © 2025

  • Home
  • About us
  • Privacy Policy
  • Affiliate disclaimer