Ask Your Question

dnf guide for apt users

asked 2018-11-25 00:03:18 -0500

arpanbiswas97 gravatar image

I recently switched from Ubuntu to Fedora. Having a little problem adopting to dnf. In Ubuntu I used to do apt update and then apt upgrade to update all softwares. What is the dnf alternative to apt update in Fedora? Is doing dnf upgrade enough? Also what is the difference between dnf upgrade and dnf upgrade --refresh?

edit retag flag offensive close merge delete


hhlp gravatar imagehhlp ( 2018-11-25 03:57:25 -0500 )edit

See . You will want to look at the unique features such as package search and history and provides

Panther gravatar imagePanther ( 2018-11-25 10:19:08 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2018-11-25 02:19:21 -0500

esbentoke gravatar image

You don't have to 'update' with dnf. It automatically keeps track of whether it's metadata is outdated and needs updating. So the dnf alternative to 'apt update && apt upgrade' is simply 'dnf upgrade'. Regarding the --refresh option, 'man dnf' states:

          set metadata as expired before running the command

... translated that means that you insist that dnf's cache is outdated and therefore forces it to 'update' before running whatever command you have given.

edit flag offensive delete link more



apt update is equivalent to dnf --refresh check-update. dnf update and dnf upgrade does the same thing.

villykruse gravatar imagevillykruse ( 2018-11-25 06:39:07 -0500 )edit

Question Tools


Asked: 2018-11-25 00:03:18 -0500

Seen: 161 times

Last updated: Nov 25 '18