How to upgrade packages that are not listed in the gnome software through the terminal

HI there,

I have a few programs that I use called mailspring and flameshot and binance.

They both have updates listed which I cannot see in the gnome software.

When i type dnf list installed

i get the output:

binance.x86_64                                             1.14.1-1                                         @@commandline                                  
flameshot.x86_64                                           0.9.0-1.fc33                                   @updates  
mailspring.x86_64                                          1.8.0-0.1                                        @@commandline 
  
                               

My question is, is there a command I can type into the terminal that will allow me to update these?

I cannot see the flameshot updates listed in gnome software and also mailspring is not listed.

I tried to download and install the packages directly from the developer at github and also their website but when i download the rpm file and try to unpackage it it doesn’t update the program.

You can use the dnf upgrade command

dnf upgrade <packages> will upgrade the listed packages and its dependences.

From man dnf

 Upgrade Command
       Command: upgrade
       Aliases: up
       Deprecated aliases: update, upgrade-to, update-to, localupdate

       dnf [options] upgrade
              Updates each package to the latest version that is both available and resolvable.

       dnf [options] upgrade <package-spec>...
              Updates each specified package to the latest available version. Updates dependencies as necessary. When versions are
              specified in the <package-spec>, update to these versions.

       dnf [options] upgrade @<spec>...
              Alias for the dnf module update command.

       If the main obsoletes configure option is true or the --obsoletes flag is present, dnf will include  package  obsoletes  in
       its calculations.  For more information see obsoletes.
3 Likes

Try:

pkcon refresh force

then kill and restart gnome-software:

pkill -f gnome-software

If you search the forums, you’ll see multiple posts about Gnome Software and DNF not being in sync, because they have their own metadata copies and update frequencies. If there are updates available, both will show them, but sometimes one may need a metadata refresh, which is what we’re doing above.

@sampsonf 's answer is a workaround here—you are using DNF to update your packages there, but it isn’t necessary. There may be cases where Gnome-software would show updates and dnf would not, it just depends on which metadata was updated most recently. dnf has a regular process that periodically updates its metadata (not sure if gnome-software has this too).

Additional note: you can also use pkcon to update your packages. It is the packagekit command line client, and gnome-software uses packagekit (not dnf):

pkcon get-updates

Again, you may need to refresh your metadata:

pkcon refresh force
3 Likes

Thanks very much, actually I tried those commands. Now when I open those apps the updates are required still pops up like before.

For example I get this message in mailspring
2021-07-22_01-08

and this message in binance:

image

and a very similar message in flameshot.

These dont get updated when I run sudo dnf update and they are not flatpaks, Which makes sense since they are not Fedora apps,

However I did install flameshot from gnome software

With regards to mailspring and binance, I get the rpm package direct from them.

For example here is mailsprings rpm package:

however i still get this message in mailspring once i download and run the rpm:
2021-07-22_01-08

the exact same thing happens with binance

When an app support self updates, the available of update is the fastest.

It will take time for it to be packaged as RPM and push to the Fedora repositories.

2 Likes

yes thats true, but this mailspring update is about 4-5 months old now and the binance update is 6 months old.

so is there a step I am missing when i download the updated rpm package. I unpack it in gnome software but it doesnt update the app.

THe only way I see is to remove the app and reinstall with the updated package but I dont want to do that.

It will be application specific.

As I do not use that app, I don’t know the details.

You can look at what is available in the repo with “dnf list ” That will tell you what version is installed and what is available. I don’t know how gnome software / packagekit can display that data but with dnf it is easy.

Remember that sometimes the version number listed in the repo might not match the version number at the upstream source even though the content is the same.

1 Like

I think @sampsonf 's made a very important note here: these apps are not from the Fedora repositories, so you must speak to the developers (or whoever is providing these rpm packages that you are using).

To update to a new version using a new rpm from your vendor:

  • download the rpm
  • run: sudo dnf install <complete path to rpm>.

if this doesn’t work, please provide the error output you get.

dnf list etc. only work for packages in a repository (could be a non Fedora repo), but they do not work for rpms that are not from repositories.

1 Like

thanks so very much it worked !

I have been trying to work out how to do that for a long time. Much appreciated. I just thought I could get that downloaded rpm directly from a source somehow as I dont like to download them from their websites, but I guess you have to sometimes

[benji@localhost Downloads]$ sudo dnf install mailspring-1.9.1-0.1.x86_64.rpm
[sudo] password for benji: 
Last metadata expiration check: 2:16:51 ago on Fri 23 Jul 2021 02:22:53 PM AEST.
Dependencies resolved.
================================================================================
 Package            Architecture   Version           Repository            Size
================================================================================
Upgrading:
 mailspring         x86_64         1.9.1-0.1         @commandline         128 M

Transaction Summary
================================================================================
Upgrade  1 Package

Total size: 128 M
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
snapper: creating pre_snapshot failed: error.io_error: .snapshots is not a btrfs subvolume
Running transaction
  Preparing        :                                                        1/1 
  Upgrading        : mailspring-1.9.1-0.1.x86_64                            1/2 
  Running scriptlet: mailspring-1.9.1-0.1.x86_64                            1/2 
  Cleanup          : mailspring-1.8.0-0.1.x86_64                            2/2 
  Running scriptlet: mailspring-1.8.0-0.1.x86_64                            2/2 
  Verifying        : mailspring-1.9.1-0.1.x86_64                            1/2 
  Verifying        : mailspring-1.8.0-0.1.x86_64                            2/2 

Upgraded:
  mailspring-1.9.1-0.1.x86_64                                                   

Complete!
[benji@localhost Downloads]$ sudo dnf install binance-x86_64-linux.rpm
Last metadata expiration check: 2:17:47 ago on Fri 23 Jul 2021 02:22:53 PM AEST.
Dependencies resolved.
================================================================================
 Package          Architecture    Version           Repository             Size
================================================================================
Upgrading:
 binance          x86_64          1.20.1-1          @commandline           82 M

Transaction Summary
================================================================================
Upgrade  1 Package

Total size: 82 M
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
snapper: creating pre_snapshot failed: error.io_error: .snapshots is not a btrfs subvolume
Running transaction
  Preparing        :                                                        1/1 
  Upgrading        : binance-1.20.1-1.x86_64                                1/2 
  Running scriptlet: binance-1.20.1-1.x86_64                                1/2 
  Cleanup          : binance-1.14.1-1.x86_64                                2/2 
  Running scriptlet: binance-1.14.1-1.x86_64                                2/2 
  Verifying        : binance-1.20.1-1.x86_64                                1/2 
  Verifying        : binance-1.14.1-1.x86_64                                2/2 

Upgraded:
  binance-1.20.1-1.x86_64   

A post was split to a new topic: Unable to install flameshot: dependency errors with DNF

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.