Linux commands to display the Operating Systems information
uname command with options
kodingwindow@kw:~$ uname
Linux

kodingwindow@kw:~$ uname -a
Linux kw 6.8.0-31-generic #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

kodingwindow@kw:~$ uname -i
x86_64

kodingwindow@kw:~$ uname -m
x86_64

kodingwindow@kw:~$ uname -n
kw

kodingwindow@kw:~$ uname -o
GNU/Linux

kodingwindow@kw:~$ uname -p
x86_64

kodingwindow@kw:~$ uname -r
6.8.0-31-generic

kodingwindow@kw:~$ uname -s
Linux

kodingwindow@kw:~$ uname -v
#31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024

kodingwindow@kw:~$ uname --help
Usage: uname [OPTION]...
Print certain system information.  With no OPTION, same as -s.

  -a, --all                print all information, in the following order,
                             except omit -p and -i if unknown:
  -s, --kernel-name        print the kernel name
  -n, --nodename           print the network node hostname
  -r, --kernel-release     print the kernel release
  -v, --kernel-version     print the kernel version
  -m, --machine            print the machine hardware name
  -p, --processor          print the processor type (non-portable)
  -i, --hardware-platform  print the hardware platform (non-portable)
  -o, --operating-system   print the operating system
      --help     display this help and exit
      --version  output version information and exit

GNU coreutils online help: https://www.gnu.org/software/coreutils/
Full documentation at: https://www.gnu.org/software/coreutils/uname
or available locally via: info '(coreutils) uname invocation'

kodingwindow@kw:~$ uname --version
uname (GNU coreutils) 9.4
Copyright (C) 2023 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later .
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by David MacKenzie.
kodingwindow@kw:~$ hostname kw kodingwindow@kw:~$ finger Login Name Tty Idle Login Time Office Office Phone kodingwindow Kodingwindow *:0 May 31 10:48 (:0)
lsb_release command with options
kodingwindow@kw:~$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 24.04 LTS
Release:	24.04
Codename:	noble

kodingwindow@kw:~$ lsb_release -c
No LSB modules are available.
Codename:	noble

kodingwindow@kw:~$ lsb_release -d
No LSB modules are available.
Description:	Ubuntu 24.04 LTS

kodingwindow@kw:~$ lsb_release -i
No LSB modules are available.
Distributor ID: Ubuntu

kodingwindow@kw:~$ lsb_release -r
No LSB modules are available.
Release:	24.04

kodingwindow@kw:~$ lsb_release -s
No LSB modules are available.

kodingwindow@kw:~$ lsb_release -h
Usage: lsb_release [options]

Options:
  -h, --help         show this help message and exit
  -v, --version      show LSB modules this system supports
  -i, --id           show distributor ID
  -d, --description  show description of this distribution
  -r, --release      show release number of this distribution
  -c, --codename     show code name of this distribution
  -a, --all          show all of the above information
  -s, --short        show requested information in short format
System information using cat command
kodingwindow@kw:~$ cat /proc/version
Linux version 6.8.0-31-generic (buildd@lcy02-amd64-080) (x86_64-linux-gnu-gcc-13 (Ubuntu 13.2.0-23ubuntu4) 13.2.0, GNU ld (GNU Binutils for Ubuntu) 2.42) #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024

kodingwindow@kw:~$ cat /proc/sys/kernel/{ostype,osrelease,version}
Linux
6.8.0-31-generic
#31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024

kodingwindow@kw:~$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=24.04
DISTRIB_CODENAME=noble
DISTRIB_DESCRIPTION="Ubuntu 24.04 LTS"

kodingwindow@kw:~$ cat /etc/issue.net
Ubuntu 24.04 LTS

kodingwindow@kw:~$ cat /etc/debian_version
trixie/sid

kodingwindow@kw:~$ cat /etc/os-release
PRETTY_NAME="Ubuntu 24.04 LTS"
NAME="Ubuntu"
VERSION_ID="24.04"
VERSION="24.04 LTS (Noble Numbat)"
VERSION_CODENAME=noble
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=noble
LOGO=ubuntu-logo
Advertisement