centos 7.4无法从epel安装`dnf`


8

太奇怪了,我有一个centos7 VM盒子。请尝试安装,dnf因为它是另一个软件包的依赖项。

互联网上的大多数说明如下:

sudo yum install epel-release
sudo yum install dnf

但是没有安装。 No package dnf available

甚至跟随DNF博客:http : //dnf.baseurl.org/2016/07/01/fresh-dnf-for-rhel-7-and-centos-7/

# cat <<EOF > /etc/yum.repos.d/dnf-stack-el7.repo
[dnf-stack-el7]
name=Copr repo for dnf-stack-el7 owned by @rpm-software-management
baseurl=https://copr-be.cloud.fedoraproject.org/results/@rpm-software-management/dnf-stack-el7/epel-7-\$basearch/
skip_if_unavailable=True
gpgcheck=1
gpgkey=https://copr-be.cloud.fedoraproject.org/results/@rpm-software-management/dnf-stack-el7/pubkey.gpg
enabled=1
enabled_metadata=1

仍然没有安装

# cat /etc/centos-release
CentOS Linux release 7.4.1708 (Core)

# yum search dnf
Loading mirror speeds from cached hostfile
 * base: centos.bhs.mirrors.ovh.net
 * epel: mirror.umd.edu
 * extras: centos.bhs.mirrors.ovh.net
 * remi-safe: remi.mirror.ate.info
 * updates: centos.bhs.mirrors.ovh.net
========================================================================= N/S matched: dnf ==========================================================================
dnf-langpacks.noarch : Langpacks plugin for dnf
dnf-langpacks-conf.noarch : Configuration file for DNF Langpacks plugin
etckeeper-dnf.noarch : DNF plugin for etckeeper support
python-dnf-langpacks.noarch : Langpacks plugin for dnf-2
mirrormanager2-mirrorlist.noarch : MirrorList serving mirrors to yum/dnf

如何安装dnf?我认为这应该是一件小事。我做错了什么?


python3-dnf已从打破dnf的EPEL 7中退出。我正在研究除epel之外的其他解决方案。当我找到合理的解决方案时,将发布答案。
Michael Hobbs

@MichaelHobbs我从没有发布的聚集,没有合理的解决方案😢?
菲利普

Answers:


4

警告:EPEL 7 DNF很老,并且存在包含安全漏洞的问题。这似乎是它被删除的原因。这就是说要在Centos 7上运行它的解决方法。

wget http://springdale.math.ias.edu/data/puias/unsupported/7/x86_64/dnf-conf-0.6.4-2.sdl7.noarch.rpm
wget http://springdale.math.ias.edu/data/puias/unsupported/7/x86_64//dnf-0.6.4-2.sdl7.noarch.rpm
wget http://springdale.math.ias.edu/data/puias/unsupported/7/x86_64/python-dnf-0.6.4-2.sdl7.noarch.rpm
yum install python-dnf-0.6.4-2.sdl7.noarch.rpm  dnf-0.6.4-2.sdl7.noarch.rpm dnf-conf-0.6.4-2.sdl7.noarch.rpm

好吧,我放弃。去年,DNF引起了很大的反响,但无声地从centos epel中删除了。我不再使用任何依赖于DNF的东西。
Reed

1
当我有时间时,后者将更新答案以包括如何构建dnf的最新版本。在查看生成选项时,生成说明要求您已安装dnf来生成dnf。真?
Michael Hobbs

我知道了Error: Package: python2-libcomps-0.1.8-3.el7.x86_64 (epel) Requires: libcomps(x86-64) = 0.1.8-3.el7
vabada '17

2

这将在CentOS / 7上安装dnf-0.6.4。

curl -OL https://raw.githubusercontent.com/tamama/repository/master/sh/tamama/node-provisioning/tamama-centos/7.3/setup.sh
sudo sh setup.sh

2
“将这个随机的shell脚本卷曲到您的生产服务器上并以root身份运行它”
Jonathan Landrum
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.