确定安装的内核版本
有多种方法可以确定 Linux 系统上安装的内核版本。以下说明涵盖了最常见的方法:
1,通过 SSH 或直接登录计算实例。
2,运行以下命令之一显示内核版本:
-
uname -r: 只输出一行内核版本。
-
hostnamectl: 输出系统详细信息的有序列表,包括内核版本。只能在有 systemd 的发行版(Debian、Ubuntu、CentOS、openSUSE 等)上使用。
-
cat /proc/version: 输出包含内核版本和发行版详细信息的字符串。
内核版本应该是一个类似于 5.4.0-80-generic 的字符串。在本例中,内核以 generic 结尾,这在 Ubuntu 系统中很常见,表示这是一个上游内核。如果内核以类似于 linode123 结尾,则表示使用的是 Linode 内核,且字符串与精确的 Linode 内核版本一致。
| Determine Which Kernel Is Installed There are may ways you can determine which kernel version is installed on your Linux system. The following instructions cover the most common methods: 1. Log in to the Compute Instance through either SSH or directly. 2. Run one of the following commands to display the kernel version: |

本文介绍了在Linux系统上通过SSH、命令行工具(如`uname-r`、`hostnamectl`和`cat/proc/version`)确定内核版本的几种常见方法,特别提到了Ubuntu和CentOS等系统中内核版本的不同标识。
最低0.47元/天 解锁文章
1873

被折叠的 条评论
为什么被折叠?



