Centos6.5离线安装lsb_release
Posted 水上云天
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Centos6.5离线安装lsb_release相关的知识,希望对你有一定的参考价值。
参考 http://www.linuxfromscratch.org/blfs/view/systemd/postlfs/lsb-release.html
首先在其他电脑下载lsb_release源码
地址 https://downloads.sourceforge.net/lsb/lsb-release-1.4.tar.gz
检验MD5 30537ef5a01e0ca94b7b8eb6a36bb1e4
上传到Centos服务器。
检验MD5
[root@dvs0 dev]# md5sum lsb-release-1.4.tar.gz 30537ef5a01e0ca94b7b8eb6a36bb1e4 lsb-release-1.4.tar.gz
解压
[root@dvs0 dev]# tar -zxvf lsb-release-1.4.tar.gz [root@dvs0 dev]# cd lsb-release-1.4 [root@dvs0 lsb-release-1.4]#
First fix a minor display problem:
[root@dvs0 lsb-release-1.4]# sed -i "s|n/a|unavailable|" lsb_release
下面开始安装:
[root@dvs0 lsb-release-1.4]# ./help2man -N --include ./lsb_release.examples --alt_version_key=program_version ./lsb_release > lsb_release.1 [root@dvs0 lsb-release-1.4]# install -v -m 644 lsb_release.1 /usr/share/man/man1 && > install -v -m 755 lsb_release /usr/bin && > install -v -m 755 help2man /usr/bin
安装结果:
`lsb_release.1\' -> `/usr/share/man/man1/lsb_release.1\' `lsb_release\' -> `/usr/bin/lsb_release\' `help2man\' -> `/usr/bin/help2man\'
测试lsb_release
[root@dvs0 lsb-release-1.4]# lsb_release -a LSB Version: unavailable Distributor ID: CentOS Description: CentOS release 6.5 (Final) Release: 6.5 Codename: Final
如果安装第一步提示:
[root@dvs0 lsb-release-1.4]# ./help2man -N --include ./lsb_release.examples --alt_version_key=program_version ./lsb_release > lsb_release.1 -bash: ./help2man: /usr/bin/perl: bad interpreter: No such file or directory
需要安装perl,按照官网提示下载安装即可。
https://www.cpan.org/src/README.html
以上是关于Centos6.5离线安装lsb_release的主要内容,如果未能解决你的问题,请参考以下文章
CentOS6.5安装之DNS配置错误,yum install 软件报错:ERROR 6或者56错误提示”could not retrieve mirrorlist http://mirrorli(代