Ask Your Question
2

How to reinstall dnf?

asked 2017-12-27 00:08:58 -0500

Dixit gravatar image

please suggest how i can reinstall dnf completed. the /etc/dnf directory has been removed accidentally.

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted
2

answered 2017-12-27 10:02:39 -0500

villykruse gravatar image

If /etc/dnf is the only thing missing, dnf is still functional. Following would then re-install most of the dnf packages.

sudo dnf reinstall '*dnf*'

The package dnf-conf is the package providing the /etc/dnf and its contents.

edit flag offensive delete link more
2

answered 2017-12-27 00:43:46 -0500

davidva gravatar image
su
yum-deprecated -y reinstall dnf dnf-conf

enjoy!

edit flag offensive delete link more

Comments

Thanks for your response.

System itself says you should use dnf instead yum. i am on fedora 24. i guess dnf becomes the default package manager since fedora 22.

command output.

root@localhost ~]# sudo yum-deprecated -y reinstall dnf dnf-conf Yum command has been deprecated, use dnf instead. See 'man dnf' and 'man yum2dnf' for more information.

Dixit gravatar imageDixit ( 2017-12-27 01:09:34 -0500 )edit

Don't matter, it should work,,,

davidva gravatar imagedavidva ( 2017-12-27 02:19:44 -0500 )edit
1

it should sill work as long a the package yum is already installed. Gnome Software may also work.

villykruse gravatar imagevillykruse ( 2017-12-27 10:04:10 -0500 )edit
0

answered 2017-12-27 01:03:06 -0500

abadrinath gravatar image

RPM reinstall could do it too.

http://rpm.org/wiki/Releases/4.12.0

edit flag offensive delete link more

Comments

Hello, Thanks for response. i don't have it dnf package to be reinstall (dnf.rpm). sharing the command output as below - [root@localhost ~]# rpm -qa | grep dnf python3-dnf-1.1.10-1.fc23.noarch python3-dnf-plugins-core-0.1.21-3.fc23.noarch dnf-yum-1.1.10-1.fc23.noarch dnf-conf-1.1.10-1.fc23.noarch dnf-plugins-core-0.1.21-3.fc23.noarch dnf-1.1.10-1.fc23.noarch

Dixit gravatar imageDixit ( 2017-12-27 01:06:57 -0500 )edit
1

It should be this one: dnf-yum-1.1.10-1.fc23.noarch

abadrinath gravatar imageabadrinath ( 2017-12-27 02:00:23 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2017-12-27 00:08:58 -0500

Seen: 1,250 times

Last updated: Dec 27 '17