当前位置:首页 > Linux > 正文内容

解决 CentOS 中 lsb_release command not found

爱与心1年前 (2022-04-30)Linux1167
在Linux经常用lsb_release 查看系统的版本。我在安装了CentOS7后,用此命令时,提示找不到。
安装

1. 用yum查看lsb_release 属于哪个程序包里

yum provides */lsb_release
2. 查询到属于redhat-lsb-core-4.1-27
redhat-lsb-core-4.1-27.el7.centos.1.x86_64 : LSB Core module support
Repo        : @base
Matched from:
Filename    : /usr/bin/lsb_release

3. 安装redhat-lsb-core

yum install redhat-lsb-core
使用
执行lsb_release可以看到相关系统版本信息了。
lsb_release -a

image.png

    扫描二维码使用手机访问。

    版权声明:本文由爱与心(www.91phper.cn)发布,如需转载请注明出处。

    本文链接:https://www.91phper.cn/post/3.html

    标签: Linux
    分享给朋友:
    返回列表

    没有更早的文章了...

    下一篇:Linux 下 .tar.gz 文件解压缩命令

    “解决 CentOS 中 lsb_release command not found” 的相关文章

    CentOS 7 迁移至 Rocky Linux 8.7

    前言CentOS 8已经在2021年12月31日结束支持,CentOS 7由于用户基数与用户贡献较多,因此会按照计划维护至生命周期结束即 2024 年 6 月 30 日,接下来一年会把重心放到CentOS Stream上。由于CentOS Stream相对不稳定,因此很多朋友会有从CentOS 7迁...

    发表评论

    访客

    ◎欢迎参与讨论,请在这里发表您的看法和观点。