Hey Ron,

Under normal circumstances, `dnf upgrade` will decide to automatically update its metadata depending on the age of the cache:

$ dnf repolist --verbose | grep --extended-regexp '^Repo-(id|expire)'
Last metadata expiration check: 0:03:23 ago on Fri 21 May 2021 10:18:52 AM EDT.
Repo-id : fedora
Repo-expire : 604,800 second(s) (last: Sat 15 May 2021 12:40:46 AM EDT)
Repo-id : fedora-cisco-openh264
Repo-expire : 1,209,600 second(s) (last: Fri 21 May 2021 10:18:40 AM EDT)
Repo-id : google-chrome
Repo-expire : 172,800 second(s) (last: Fri 21 May 2021 10:18:50 AM EDT)
Repo-id : rpmfusion-free
Repo-expire : 1,209,600 second(s) (last: Fri 21 May 2021 10:18:50 AM EDT)
Repo-id : rpmfusion-free-updates
Repo-expire : 172,800 second(s) (last: Fri 21 May 2021 10:18:51 AM EDT)
Repo-id : rpmfusion-nonfree
Repo-expire : 1,209,600 second(s) (last: Fri 21 May 2021 10:18:51 AM EDT)
Repo-id : rpmfusion-nonfree-updates
Repo-expire : 172,800 second(s) (last: Fri 21 May 2021 10:18:52 AM EDT)
Repo-id : updates
Repo-expire : 21,600 second(s) (last: Fri 21 May 2021 10:18:43 AM EDT)

This has the benefit of keeping package metadata up to date so installing outdated packages doesn't happen often.

Running `dnf upgrade --refresh` will have a similar effect to `apt update && apt full-upgrade`, where you'd be forcing a metadata cache update with every upgrade.

You can also force dnf to stick to just the local cache and skip metadata updates with `dnf upgrade --cacheonly`. You can learn more about different supported options by running `dnf upgrade --help`.

- Josh




On Fri, 2021-05-21 at 14:08 +0000, THE HAMMER via WLUG wrote:
I just installed Fedora 34 on a "junk laptop" to play along with.  Looked on line and wound up with a couple different answers, and so perhaps they are all correct.  My question is when I want to update all the packages in the lap top what is the correct/best command?

Also what is the difference between

dnf upgrade

and

dnf upgrade --refresh

Thanks

Ron
_______________________________________________
WLUG mailing list -- wlug@lists.wlug.org
To unsubscribe send an email to wlug-leave@lists.wlug.org
Create Account: https://wlug.mailman3.com/accounts/signup/
Change Settings: https://wlug.mailman3.com/postorius/lists/wlug.lists.wlug.org/
Web Forum/Archive: https://wlug.mailman3.com/hyperkitty/list/wlug@lists.wlug.org/message/X4PARJKFKAJOERO4NZDRWZM6TXK3MXG2/