Issue
Imunify installation fails with the error such as:
[2022-08-18 17:41:52] One of the configured repositories failed (Example repo),
[2022-08-18 17:41:52] and yum doesn't have enough cached data to continue. At this point the only
[2022-08-18 17:41:52] safe thing yum can do is fail. There are a few ways to work "fix" this:
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] 1. Contact the upstream for the repository and get them to fix the problem.
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] 2. Reconfigure the baseurl/etc. for the repository, to point to a working
[2022-08-18 17:41:52] upstream. This is most often useful if you are using a newer
[2022-08-18 17:41:52] distribution release than is supported by the repository (and the
[2022-08-18 17:41:52] packages for the previous distribution release still work).
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] 3. Run the command with the repository temporarily disabled
[2022-08-18 17:41:52] yum --disablerepo=examplerepo ...
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] 4. Disable the repository permanently, so yum won't use it by default. Yum
[2022-08-18 17:41:52] will then just ignore the repository until you permanently enable it
[2022-08-18 17:41:52] again or use --enablerepo for temporary usage:
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] yum-config-manager --disable examplerepo
[2022-08-18 17:41:52] or
[2022-08-18 17:41:52] subscription-manager repos --disable=examplerepo
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] 5. Configure the failing repository to be skipped, if it is unavailable.
[2022-08-18 17:41:52] Note that yum will try to contact the repo. when it runs most commands,
[2022-08-18 17:41:52] so will have to try and fail each time (and thus. yum will be be much
[2022-08-18 17:41:52] slower). If it is a very temporary problem though, this is often a nice
[2022-08-18 17:41:52] compromise:
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] yum-config-manager --save --setopt=examplerepo.skip_if_unavailable=true
[2022-08-18 17:41:52]
[2022-08-18 17:41:52] failure: repodata/repomd.xml from examplerepo: [Errno 256] No more mirrors to try.
[2022-08-18 17:41:52] http://download.example.com/centos/7/repodata/repomd.xml: [Errno 14] HTTPS Error 403 - Forbidden
[2022-08-18 17:41:52] Package imunify-antivirus was not installed.
Environment
- Imunify360
- ImunifyAV
- Installation
- CentOS
- CloudLinux
- AlmaLinux
Solution
-
Set the problem repository to be skipped when not available:
# yum-config-manager --save --setopt=examplerepo.skip_if_unavailable=true
Or:
-
Remove the problem repo files:
# grep -r "download.example.com" /etc/yum.repos.d
/etc/yum.repos.d/example-testing.repo:mirrorlist=http://download.example.com/centos/7/repodata/repomd.xml
/etc/yum.repos.d/example.repo:mirrorlist=http://download.example.com/centos/7/repodata/repomd.xml# mv /etc/yum.repos.d/example* ~/
-
Clear yum cache:
# yum clean all
Cause
One or more repositories added previously are unavailable.
Comments
0 comments
Please sign in to leave a comment.