In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
This article is to share with you about how to determine the linux version number. The editor thought it was very practical, so I shared it with you as a reference. Let's follow the editor and have a look.
How to determine the linux version number? In fact, when people refer to Linux, they usually refer to the Linux distribution; but strictly speaking, Linux is a kernel, while the Linux distribution is an operating system made up of the Linux kernel, GNU tools and libraries, and software collections.
How does linux check the version number?
Method 1: use the uname command to check the linux kernel version number
The uname command displays multiple system information, including the Linux kernel architecture, name version, and release.
To find out which version of the Linux kernel is running on the system, type:
Uname-srm
Output
Linux 4.9.0-8-amd64 x861464
The above output tells us that the Linux kernel is 64-bit and its version is "4.9.0-8-amd64".
Method 2: use the hostnamectl command
Hostnamectl is part of systemd and can be used to query and change the system hostname. The command also displays the Linux distribution and kernel version.
Hostnamectl
Output:
Static hostname: debian9.localdomaincon name: computer-vmChassis: vmMachine ID: a92099e30f704d559adb18ebc12ddac4Boot ID: 7607cbe605d44f638d6542d4c7b3878eVirtualization: qemuOperating System: Debian GNU/Linux 9 (stretch) Kernel: Linux 4.9.0-8-amd64Architecture: x86-64
The above output tells us that the Linux kernel is 64-bit and its version is "4.9.0-8-amd64"; the release is "Debian GNU/Linux 9 (stretch)" with version number 9.
Method 3: use the lsb_release command
Lsb_release applications can display LSB (Linux Standard Library) information about Linux distributions; this lsb_release command applies to all Linux distributions that have lsb-release packages installed:
Lsb_release-a
Output:
No LSB modules are available.Distributor ID:DebianDescription:Debian GNU/Linux 9.5 (stretch) Release:9.5Codename:stretch
The Linux release and version are displayed in the "Description" line. As you can see from the output above, Debian GNU / Linux 9.5 (stretch) is installed on my system.
Method 4: use the cat / etc/os-release command
The / etc / os-release file contains operating system identification data, including information about distribution. This file is part of systemd and should be available on linux systems running systemd.
To view the contents of the os-release file, you need to run the following cat command:
Cat / etc/os-release
The output is as follows:
PRETTY_NAME= "Debian GNU/Linux 9 (stretch)" NAME= "Debian GNU/Linux" VERSION_ID= "9" VERSION= "9 (stretch)" ID=debianHOME_URL= "https://www.debian.org/"SUPPORT_URL="https://www.debian.org/support"BUG_REPORT_URL="https://bugs.debian.org/"
Method 5: use the cat / etc/issue command
The / etc/issue file contains the system identification text that is displayed before the login prompt. Typically, this file contains information about the Linux version:
To view the contents of the issue file, you need to run the following cat command:
Cat / etc/issue
The output is as follows:
Debian GNU/Linux 9\ n\ l Thank you for reading! On how to determine the linux version number to share here, I hope the above content can be of some help to you, so that you can learn more knowledge. If you think the article is good, you can share it and let more people see it.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.