I need to install MongoDB community edition on an Amazon Linux machine.
I followed the steps described in the MongoDB documentation that are, very simply:
- Create the repo file in
/etc/yum.repos.d
- Intall via
sudo yum install -y mongodb-org
However, I get a dependency error that I cannot go past. Here's the output:
sh-4.2$ sudo yum install -y mongodb-org
Loaded plugins: dkms-build-requires, priorities, update-motd, upgrade-helper, versionlock
amzn-main | 2.1 kB 00:00:00
amzn-updates | 2.5 kB 00:00:00
libnvidia-container/x86_64/signature | 455 B 00:00:00
libnvidia-container/x86_64/signature | 2.0 kB 00:00:00 !!!
mongodb-org-4.2 | 2.4 kB 00:00:00
Not using downloaded repomd.xml because it is older than what we have:
Current : Mon Dec 9 22:52:43 2019
Downloaded: Mon Dec 9 22:52:27 2019
nvidia-container-runtime/x86_64/signature | 455 B 00:00:00
nvidia-container-runtime/x86_64/signature | 2.0 kB 00:00:00 !!!
nvidia-docker/x86_64/signature | 455 B 00:00:00
nvidia-docker/x86_64/signature | 2.0 kB 00:00:00 !!!
Resolving Dependencies
--> Running transaction check
---> Package mongodb-org.x86_64 0:4.2.2-1.amzn2 will be installed
--> Processing Dependency: mongodb-org-tools = 4.2.2 for package: mongodb-org-4.2.2-1.amzn2.x86_64
--> Processing Dependency: mongodb-org-shell = 4.2.2 for package: mongodb-org-4.2.2-1.amzn2.x86_64
--> Processing Dependency: mongodb-org-server = 4.2.2 for package: mongodb-org-4.2.2-1.amzn2.x86_64
--> Processing Dependency: mongodb-org-mongos = 4.2.2 for package: mongodb-org-4.2.2-1.amzn2.x86_64
--> Running transaction check
---> Package mongodb-org-mongos.x86_64 0:4.2.2-1.amzn2 will be installed
--> Processing Dependency: libc.so.6(GLIBC_2.18)(64bit) for package: mongodb-org-mongos-4.2.2-1.amzn2.x86_64
---> Package mongodb-org-server.x86_64 0:4.2.2-1.amzn2 will be installed
--> Processing Dependency: libc.so.6(GLIBC_2.18)(64bit) for package: mongodb-org-server-4.2.2-1.amzn2.x86_64
---> Package mongodb-org-shell.x86_64 0:4.2.2-1.amzn2 will be installed
--> Processing Dependency: libc.so.6(GLIBC_2.18)(64bit) for package: mongodb-org-shell-4.2.2-1.amzn2.x86_64
---> Package mongodb-org-tools.x86_64 0:4.2.2-1.amzn2 will be installed
--> Finished Dependency Resolution
Error: Package: mongodb-org-shell-4.2.2-1.amzn2.x86_64 (mongodb-org-4.2)
Requires: libc.so.6(GLIBC_2.18)(64bit)
Error: Package: mongodb-org-mongos-4.2.2-1.amzn2.x86_64 (mongodb-org-4.2)
Requires: libc.so.6(GLIBC_2.18)(64bit)
Error: Package: mongodb-org-server-4.2.2-1.amzn2.x86_64 (mongodb-org-4.2)
Requires: libc.so.6(GLIBC_2.18)(64bit)
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
In addition, when I run yum whatprovides */libc.so.6
, I understand that that file is already installed on the machine:
Loaded plugins: dkms-build-requires, priorities, update-motd, upgrade-helper, versionlock
libnvidia-container 40/40
nvidia-container-runtime 18/18
nvidia-docker 14/14
mongodb-org-4.2/filelists_db | 2.8 kB 00:00:00
glibc-2.17-196.172.amzn1.i686 : The GNU libc libraries
Repo : amzn-main
Matched from:
Filename : /lib/i686/nosegneg/libc.so.6
Filename : /lib/libc.so.6
glibc-2.17-196.172.amzn1.x86_64 : The GNU libc libraries
Repo : amzn-main
Matched from:
Filename : /lib64/libc.so.6
glibc-2.17-222.173.amzn1.i686 : The GNU libc libraries
Repo : amzn-updates
Matched from:
Filename : /lib/i686/nosegneg/libc.so.6
Filename : /lib/libc.so.6
glibc-2.17-222.173.amzn1.x86_64 : The GNU libc libraries
Repo : amzn-updates
Matched from:
Filename : /lib64/libc.so.6
glibc-2.17-260.175.amzn1.i686 : The GNU libc libraries
Repo : amzn-updates
Matched from:
Filename : /lib/i686/nosegneg/libc.so.6
Filename : /lib/libc.so.6
glibc-2.17-260.175.amzn1.x86_64 : The GNU libc libraries
Repo : amzn-updates
Matched from:
Filename : /lib64/libc.so.6
glibc-2.17-292.178.amzn1.i686 : The GNU libc libraries
Repo : amzn-updates
Matched from:
Filename : /lib/i686/nosegneg/libc.so.6
Filename : /lib/libc.so.6
glibc-2.17-292.178.amzn1.x86_64 : The GNU libc libraries
Repo : amzn-updates
Matched from:
Filename : /lib64/libc.so.6
glibc-2.17-292.178.amzn1.x86_64 : The GNU libc libraries
Repo : @amzn-updates
Matched from:
Filename : /lib64/libc.so.6
Hence, what should I do to overcome this obstacle?
yum -y update
first.