It seems mongodb require specific version of libssl1.1
- you can download debian file of that version and install using following commands. Most probably it will resolve this issue.
sudo wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb
sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb
Answer from Santosh Gusain on Stack OverflowWhen I try to run the flycast.elf file to run dreamcast, I get this error:
./flycast.elf: error while loading shared libraries: libzip.so.5: cannot open shared object file: No such file or directory.
And when I try installing libzip5 with "sudo apt install libzip5", I get this error:
E: Unable to locate package libzip5
How do I approach this issue? Thank you for your assistance.
It seems mongodb require specific version of libssl1.1
- you can download debian file of that version and install using following commands. Most probably it will resolve this issue.
sudo wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb
sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb
After hours of looking for a solution I was satisfied with, I finally stumbled across one! Hope this helps anyone else looking to install MongoDB community edition without sacrificing security by using libssl1.1 (the solution here uses >3.0.
MongoDB has the repository for Ubuntu 22.04.1 LTS (Jammy Jellyfish) hidden away. It definitely still isn't on the documentation installation pages as of the time I am posting this. Check it out yourself: https://repo.mongodb.org/apt/ubuntu/dists/jammy/mongodb-org/
The following code will add the repository and install the latest mongodb-org on your system:
sudo apt-get install wget gpg
wget -qO - https://www.mongodb.org/static/pgp/server-6.0.asc | gpg --dearmor > packages.mongodb.gpg
sudo install -D -o root -g root -m 644 packages.mongodb.gpg /etc/apt/keyrings/packages.mongodb.gpg
echo "deb [ arch=amd64,arm64 signed-by=/etc/apt/keyrings/packages.mongodb.gpg] https://repo.mongodb.org/apt/ubuntu jammy/mongodb-org/6.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-6.0.list
rm -f packages.mongodb.gpg
sudo apt-get install -y mongodb-org
Note that libssl1.0.0 is obsolete and no longer updated; any binary linking to it probably suffers from various security issues (perhaps not exploitable, but you’d need to determine that in your scenarios). You should really look for a newer version of whatever it is you’re trying to use.
However, you can find libssl1.0.0 on Debian snapshots; download the appropriate package and install it. For example on amd64:
wget http://snapshot.debian.org/archive/debian/20170705T160707Z/pool/main/o/openssl/libssl1.0.0_1.0.2l-1%7Ebpo8%2B1_amd64.deb
sudo dpkg -i libssl1.0.0*.deb
You may need to install multiarch-support first:
wget http://snapshot.debian.org/archive/debian/20190501T215844Z/pool/main/g/glibc/multiarch-support_2.28-10_amd64.deb
sudo dpkg -i multiarch-support*.deb
(Having this library installed only affects binaries which link to it; it won’t create security issues for other binaries linking to other versions of the library.)
I was facing a libssl1.1 issue when trying to install mongo-db in Pop!_OS 22.04 LTS (or Ubuntu 22.04 LTS).
As @stephen-kitt mentioned libssl1.x is an obsolete package. So you need to manually install the required package.
- Go to this page
- Find the exact version of libssl for example libssl1.1.1
wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1-1ubuntu2.1~18.04.20_amd64.deb(use your version url respectively)- Then install with
sudo dpkg -i libssl1.1_1.1.1-1ubuntu2.1~18.04.20_amd64.deb
Hope this helps others who are trying to do the same.
The issue is referenced on Github, all credit goes to @feisalramar.
I have resolved the issue by installing libssl manually.
wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.0g-2ubuntu4_amd64.deb
sudo dpkg -i libssl1.1_1.1.0g-2ubuntu4_amd64.deb
I've encountered this issue with 22.04 LTS, ended up writing the following script for my systems to have it installed, as one of the tools I use to setup the system requires it.
Hope others find this useful.
# Find the most recent 1.1 libssl package in the ubuntu archives
BASE_URL='http://archive.ubuntu.com/ubuntu/pool/main/o/openssl'
FILE="$( # The get parameters in the URL sort the results by descending chronological order
curl -s "${BASE_URL}/?C=M;O=D" $(\
# Make sure all tags are on separate lines - makes grep-work later easier \
) | tr '>' '>\n' $(\
# extract all the unique links on the page \
) | grep 'href' | sed 's/^.*href="\([^"]*\)".*$/\1/p' | awk '!a[$0]++' $(\
# pick the most relevant items on the list (libssl 1.1 for amd64 arch) \
) | grep "libssl" | grep "1.1_" | grep "amd64.deb" $(\
# choose only the last one \
) | tail -1 )"
# Grab the file and if download was successful, install it with sudo
wget "${URL_BASE}/${FILE}" && sudo dpkg -i "./${FILE}"
Edit december 2022
MongoDB 6.0 is now installable from mongodb repositories on Jammy, without requiring libssl1.1
Original answer
MongoDb has no official build for ubuntu 22.04 at the moment.
Ubuntu 22.04 has upgraded libssl to 3 and does not propose libssl1.1
You can force the installation of libssl1.1 by adding the ubuntu 20.04 source:
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
sudo apt-get update
sudo apt-get install libssl1.1
Then use your commands to install mongodb-org.
Then delete the focal-security list file you just created:
sudo rm /etc/apt/sources.list.d/focal-security.list
Ubuntu 22.04 doesn't have official MongoDB packages yet, so the best option now is to have Ubuntu 20.04, where official MongoDB packages are available.
It's NOT recommended to use any workaround in Ubuntu 22.04 to install MongoDB, because it can lead to problems if you gonna use it in production. Below is the workaround that worked for me:
Download
libssl1.1_1.1.1f-1ubuntu2_amd64.debfrom official repository:wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.debInstall it:
sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.debProceed with the installation of MongoDB:
sudo apt-get install -y mongodb-org
This solution is from MongoDB Forum, but I also added a few notes to keep in mind.
I see two options:
Try to install
libsslmanually (the exact version from official repository):sudo apt install libssl1.1=1.1.0g-2ubuntu4.3Remove
ppa:ondrej/phpfrom the system:sudo apt install ppa-purge sudo ppa-purge ppa:ondrej/phpand then install
lighttpdsudo apt install lighttpd
I had the same issue. I downloaded the lighttpd .deb package and ran dpkg which gave some more insight:
libssl1.1:armhf (1.1.1a-2~20190131152537.8+stretch) breaks lighttpd (<< 1.4.49-2) and is installed.
So it looks like the libssl 1.1.1a package from deb.sury.org is too new for the lighttpd 1.4.45 that comes from debian. I removed that package source and downgraded libssl after which I could install lighttpd. Alternatively you could try to get lighttpd 1.4.49 or later.
sudo -i
wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb
sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb
- Go to http://archive.ubuntu.com/ubuntu/pool/main/o/openssl
- find the exact version of libssl for example libssl1.1.1
- wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1-1ubuntu2.1\~18.04.20_amd64.deb
- Then install
- sudo dpkg -i libssl1.1_1.1.1-1ubuntu2.1~18.04.20_amd64.deb