Cannot install anything! Failed to synchronize cache for repo 'passenger', disabling

#1

Hi, I tried uninstalling ‘passenger’ today via the commands located here for Fedora: https://www.phusionpassenger.com/library/install/standalone/uninstall/oss/

The commands completed successfully. Now whenever I try to install anything or update, I get this:
Failed to synchronize cache for repo ‘passenger’, disabling.
Failed to synchronize cache for repo ‘passenger-source’, disabling.

I have searched high and low for the solution… no idea how to fix this. Just started using Fedora about a month ago. Please help!

#2

As the title suggests, it might be a problem with the repo not being able to sync. If you don’t want to get the annoying message about it, and don’t need the repo again for passenger, just disable it from Software -> Settings (upper right corner) -> Software Repositories -> Disable the 2 passenger ones.

Or simply delete the repository from the command line:

sudo rm /etc/yum.repos.d/passenger
sudo rm /etc/yum.repos.d/passenger-source
1 Like
#3

@kendrakvnhvn10 As you are a beginner I will explain this a little bit, just to complete what @biosharkdev said…

The repos are in the folder /etc/yum.repos.d. As I understand, repos are a way to get applications into your computer. Fedora comes with a lot of official repos but you can include some non-official repos. For example to install the atom text editor you need to follow this steps

To install atom

  1. sudo rpm --import https://packagecloud.io/AtomEditor/atom/gpgkey

:arrow_right: Adds key, will explain this step at the end…

  1. sudo sh -c 'echo -e "[Atom]\nname=Atom Editor\nbaseurl=https://packagecloud.io/AtomEditor/atom/el/7/\$basearch\nenabled=1\ngpgcheck=0\nrepo_gpgcheck=1\ngpgkey=https://packagecloud.io/AtomEditor/atom/gpgkey" > /etc/yum.repos.d/atom.repo'

:arrow_right: As you can see the previous command is just a way to write a repo file in the mentioned folder (every \n gives a new line, in this case the 4th line gives the option to enable enable=1 or disable enable=0 the repo file).

  1. sudo dnf install atom

:arrow_right: With this command your computer will find the atom package in the atom repo and will install it, otherwise it will say No match for argument: atom.

To remove atom

  1. sudo dnf remove atom

:arrow_right: removes the package

  1. sudo dnf config-manager --disablerepo Atom

:arrow_right: disables the repo or you could do what @biosharkdev said which deletes the repo file entirely … I prefer to do that

  1. rm .atom .config/Atom

:arrow_right: removes some folders where atom saves some files

  1. sudo rpm -e gpg-pubkey-de9e3b09-5a34231f

:arrow_right: For security reasons, some repos come with a key file. You also have to remove that key.

I hope this is clearer.

3 Likes
#4

This worked for me. Specifically this command
sudo rm /etc/yum.repos.d/passenger.repo

#5

Yes, clear explanation. Thank you.

#6

Glad to help. I had the same issue recently, that’s why the solution was fresh in my mind.

1 Like