linux yum删除nginx,linux yum安装的nginx肿么重新

解决方法:

第一步:创建一个新文件夹,并把光盘的内容全部复制到该文件夹内:

[root@localhost ~]# mkdir /yum

[root@localhost ~]# cp -rvf /misc/cd/* /yum

第二步:安装工具包:

[root@localhost ~]# rpm -ivh /yum/Server/createrepo-0.4.11-3.el5.noarch.rpm

第三步:生成仓库数据库:

[root@localhost ~]# cd /yum

[root@localhost yum]# createrepo . //注意后面的.

第四步:查看文件:

[root@localhost yum]# ls /yum/repodata/

filelists.xml.gz other.xml.gz primary.xml.gz repomd.xml

第五步:客户端配置:

[root@localhost ~]# cp /etc/yum.repos.d/rhel-debuginfo.repo /etc/yum.repos.d/chenbin.repo

[root@localhost ~]# vi /etc/yum.repos.d/chenbin.repo [rhel-chenbin]

name=Red Hat Enterprise Linux $releasever - $basearch - Debug

baseurl=file:///yum/

enabled=1

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

第六步:清除yum安装时的缓存:

[root@localhost ~]# yum clean all

取消

评论

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值