Reputation: 707
I am trying to install mongodb 4 into an amazonlinux:2018.03 docker container. I followed these instructions. I managed to install only one package: mongodb-org, but I failed to install the rest of it: mongos, server, shell, tools.
The error I am give is the following:
Error: Package: mongodb-org-mongos-4.0.2-1.amzn2.x86_64 (mongodb-org-4.0) Requires: libc.so.6(GLIBC_2.18)(64bit)
There is a libc.so.6 in /lib64 pointing to /lib64/libc-2.17.so
Any help would be appreciated. Thank you.
Upvotes: 7
Views: 5631
Reputation: 346
I had a similar issue but I followed this installation guide here; https://www.attosol.com/how-to-install-mongodb-in-aws-linux-step-by-step
You can get a more appropriate repo on this link https://www.mongodb.org/dl/linux/x86_64-amazon . My suggestion is that you experiment with the two most recent ones and see what works.
Upvotes: 0
Reputation: 2306
Cloud9 runs on the old Amazon linux instance, so you may run into this problem using the IDE. This is how I got it working for myself on Cloud9 running in an Amazon Linux instance:
File named "mongodb-org-4.2.repo"
[mongodb-org-4.2]
name=MongoDB Repository
baseurl=https://repo.mongodb.org/yum/amazon/2013.03/mongodb-org/4.2/x86_64/
gpgcheck=1
enabled=1
gpgkey=https://www.mongodb.org/static/pgp/server-4.2.asc
Then I ran the following in the same directory as that file:
sudo cp ./mongodb-org-4.2.repo /etc/yum.repos.d/mongodb-org-4.2.repo
sudo yum install -y mongodb-org
Upvotes: 1
Reputation: 341
It looks like you're using an AmazonLinux 2 MongoDB package within an AmazonLinux 1 container. You should try using the MongoDB 4.0.2 package for AmazonLinux 1.
Upvotes: 4