- Newest
- Most votes
- Most comments
I solved that by:
-
Inspecting repos before the error fires in this folder:
/etc/yum.repos.d/
-
For me, there was a custom yum repo added which caused the problem. I performed following to remove the repo after operations with it are done:
05_node_repo_remove:
cwd: /etc/yum.repos.d/
command: 'sudo rm -f nodesource-el7.repo && yum makecache'
Hi
I understand you attempting an update to 3.4.7 but the command yum makecache fails. Based on the output you have provided I see there are resolution steps provided when this issue is encountered. I advised you follow the resolution steps to try fix the issue [1]. In addition Elastic Beanstalk locks package repositories to a specific version for each of our platform versions, so yum metadata may be more likely to become stale as Amazon Linux releases package updates after the platform version has been created. Try Running yum clean metadata first, or possibly some other commands to clean yum caches such as yum clean all and rm -rf /var/cache/yum/* [2].
[1] 1. Contact the upstream for the repository and get them to fix the problem.
2. Reconfigure the baseurl/etc. for the repository, to point to a working
upstream. This is most often useful if you are using a newer
distribution release than is supported by the repository (and the
packages for the previous distribution release still work).
3. Run the command with the repository temporarily disabled
yum --disablerepo=amzn2-core ...
4. Disable the repository permanently, so yum won't use it by default. Yum
will then just ignore the repository until you permanently enable it
again or use --enablerepo for temporary usage:
yum-config-manager --disable amzn2-core
or
subscription-manager repos --disable=amzn2-core
5. Configure the failing repository to be skipped, if it is unavailable.
Note that yum will try to contact the repo. when it runs most commands,
so will have to try and fail each time (and thus. yum will be be much
slower). If it is a very temporary problem though, this is often a nice
compromise:
yum-config-manager --save --setopt=amzn2-core.skip_if_unavailable=true
[2]Third Party https://www.thegeekdiary.com/metadata-file-does-not-match-checksum-issue-when-yum-installs-or-updates-package/
The command
yum makecache
is something that Elastic beanstalk is running on it's own. I do deployments with Terraform, so the issue isn't whether or not this can be fixed on an individual basis, but if the fix can replicated in an automated way over and over again. My servers are working fine for right now. I was just trying to alert someone that the automated process for provisioning EC2 instances and deploying ruby might have an issue.
Relevant content
- AWS OFFICIALUpdated 8 months ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
I've experienced the same problem. I can deploy and run successfully on Ruby 2.7 running on 64bit Amazon Linux 2/3.3.4, but when I try to update or deploy on 3.4.7 it fails with this same error.