Cannot install MongoDB on Beaglebone Green - mongodb

The installation of MongoDB is still unsuccessful on the BeagleBone Green card.
More information about this BBG:
debian#beaglebone:/var/lib/cloud9$ uname -a
Linux beaglebone 4.9.82-ti-r102 #1 SMP PREEMPT Thu Feb 22 01:16:12 UTC 2018 armv7l GNU/Linux
debian#beaglebone:/var/lib/cloud9$ cat /etc/*-release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
Even I tried to follow this tutorial : https://docs.mongodb.com/v3.0/tutorial/install-mongodb-on-debian/ as below :
debian#beaglebone:/var/lib/cloud9$ sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5
Executing: /tmp/apt-key-gpghome.jgT79mhjhQ/gpg.1.sh --keyserver hkp://keyserver.ubuntu.com:80 --recv 2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5
gpg: key 58712A2291FA4AD5: "MongoDB 3.6 Release Signing Key <packaging#mongodb.com>" not changed
gpg: Total number processed: 1
gpg: unchanged: 1
debian#beaglebone:/var/lib/cloud9$ echo "deb http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.6 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.6.list
deb http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.6 main
debian#beaglebone:/var/lib/cloud9$ echo "deb http://repo.mongodb.org/apt/debian stretch/mongodb-org/{+package-branch+} main" | sudo tee /etc/apt/sources.list.d/mongodb-org-{+version+}.list
deb http://repo.mongodb.org/apt/debian stretch/mongodb-org/{+package-branch+} main
debian#beaglebone:/var/lib/cloud9$ sudo apt-get update
Ign:1 http://deb.debian.org/debian stretch InRelease
Hit:2 http://deb.debian.org/debian stretch-updates InRelease
Get:3 http://deb.debian.org/debian-security stretch/updates InRelease [94.3 kB]
Ign:4 http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.6 InRelease
Hit:5 http://repos.rcn-ee.com/debian stretch InRelease
Hit:6 http://deb.debian.org/debian stretch Release
Get:7 http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.6 Release [2393 B]
Get:8 http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.6 Release.gpg [801 B]
Fetched 97.5 kB in 5s (17.8 kB/s)
Reading package lists... Done
N: Skipping acquire of configured file 'main/binary-armhf/Packages' as repository 'http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.6 InRelease' doesn't support architecture 'armhf'
debian#beaglebone:/var/lib/cloud9$ sudo apt-get install -y mongodb-org
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package mongodb-org
debian#beaglebone:/var/lib/cloud9$ sudo apt-get install -y mongodb-org=3.6.4 mongodb-org-server=3.6.4 mongodb-org-shell=3.6.4 mongodb-org-mongos=3.6.4 mongodb-org-tools=3.6.4
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package mongodb-org
E: Unable to locate package mongodb-org-server
E: Unable to locate package mongodb-org-shell
E: Unable to locate package mongodb-org-mongos
E: Unable to locate package mongodb-org-tools
debian#beaglebone:/var/lib/cloud9$ echo "mongodb-org hold" | sudo dpkg --set-selections
dpkg: warning: package not in status nor available database at line 1: mongodb-org
dpkg: warning: found unknown packages; this might mean the available database
is outdated, and needs to be updated through a frontend method;
please see the FAQ <https://wiki.debian.org/Teams/Dpkg/FAQ>
debian#beaglebone:/var/lib/cloud9$ echo "mongodb-org-server hold" | sudo dpkg --set-selections
dpkg: warning: package not in status nor available database at line 1: mongodb-org-server
dpkg: warning: found unknown packages; this might mean the available database
is outdated, and needs to be updated through a frontend method;
please see the FAQ <https://wiki.debian.org/Teams/Dpkg/FAQ>
debian#beaglebone:/var/lib/cloud9$ echo "mongodb-org-shell hold" | sudo dpkg --set-selections
dpkg: warning: package not in status nor available database at line 1: mongodb-org-shell
dpkg: warning: found unknown packages; this might mean the available database
is outdated, and needs to be updated through a frontend method;
please see the FAQ <https://wiki.debian.org/Teams/Dpkg/FAQ>
debian#beaglebone:/var/lib/cloud9$ echo "mongodb-org-mongos hold" | sudo dpkg --set-selections
dpkg: warning: package not in status nor available database at line 1: mongodb-org-mongos
dpkg: warning: found unknown packages; this might mean the available database
is outdated, and needs to be updated through a frontend method;
please see the FAQ <https://wiki.debian.org/Teams/Dpkg/FAQ>
debian#beaglebone:/var/lib/cloud9$ echo "mongodb-org-tools hold" | sudo dpkg --set-selections
dpkg: warning: package not in status nor available database at line 1: mongodb-org-tools
dpkg: warning: found unknown packages; this might mean the available database
is outdated, and needs to be updated through a frontend method;
please see the FAQ <https://wiki.debian.org/Teams/Dpkg/FAQ>
but the problem is still the same.
How can I fix this issue please?

There is no ARMv7-HF package offered by that repository.
The easiest option is to go with the Debian package:
sudo apt install mongodb
This will yield version 3.2.11 as indicated here: https://packages.debian.org/stretch/mongodb
The more complicated option is to build it from source. This will potentially take a very long time if you do it directly on the BBB!
A rough guess at steps would be:
This pulls in build dependencies for the debian mongodb, which may be sufficient, but at least should provide a decent base:
sudo apt build-dep mongo
Download source code - as of the time of me writing this it would be:
wget https://fastdl.mongodb.org/src/mongodb-src-r3.6.5.tar.gz
Unpack: tar -xvzf mongodb-src-r3.6.5.tar.gz
Change directory into source: cd mongodb-src-r3.6.5
Build debian package from source: dpkg-buildpackage -b
Install build results: dpkg -i ../mongodb-org-bla-foo.deb
The build step might possibly fail for a variety of reasons, e.g. unresolved dependencies. Please make sure to download the latest version to avoid exposing yourself to security issues and stability problems, the above mentioned URL is just an example and only valid at the time of writing.

Related

Can't install mongodb for ubuntu

Trying to install mongodb for ubuntu and can't solve the issue.
I got lost, need your help please!
Going according the docs:
https://www.mongodb.com/docs/master/tutorial/install-mongodb-on-ubuntu/
wget -qO - https://www.mongodb.org/static/pgp/server-6.0.asc | sudo apt-key add -
Result (CLI output): on mine ubuntu:
Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)).
OK
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-6.0.list
Result (CLI output):
deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 multiverse
sudo apt-get update
Result (CLI output):
et:1 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB]
Ign:2 http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/4.0 InRelease
Hit:3 http://packages.microsoft.com/repos/code stable InRelease
Hit:4 https://ppa.launchpadcontent.net/graphics-drivers/ppa/ubuntu jammy InRelease
Hit:5 http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/4.0 Release
Ign:6 https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 InRelease
Hit:7 http://il.archive.ubuntu.com/ubuntu jammy InRelease
Ign:8 https://ppa.launchpadcontent.net/upubuntu-com/xampp/ubuntu jammy InRelease
Hit:9 http://il.archive.ubuntu.com/ubuntu jammy-updates InRelease
Hit:11 https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 Release
Hit:12 http://il.archive.ubuntu.com/ubuntu jammy-backports InRelease
Err:13 https://ppa.launchpadcontent.net/upubuntu-com/xampp/ubuntu jammy Release
404 Not Found [IP: 185.125.190.52 443]
Reading package lists... Done
W: http://repo.mongodb.org/apt/ubuntu/dists/xenial/mongodb-org/4.0/Release.gpg: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
E: The repository 'https://ppa.launchpadcontent.net/upubuntu-com/xampp/ubuntu jammy Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: https://repo.mongodb.org/apt/ubuntu/dists/focal/mongodb-org/6.0/Release.gpg: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
sudo apt-get install -y mongodb-org
Result (CLI output):
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
mongodb-org-mongos : Depends: libssl1.0.0 (>= 1.0.1) but it is not installable
mongodb-org-server : Depends: libcurl3 (>= 7.16.2) but it is not installable
Depends: libssl1.0.0 (>= 1.0.1) but it is not installable
mongodb-org-shell : Depends: libssl1.0.0 (>= 1.0.1) but it is not installable
mongodb-org-tools : Depends: libssl1.0.0 (>= 1.0.2~beta3) but it is not installable
E: Unable to correct problems, you have held broken packages.
uname -m
Result (CLI output):
x86_64
lsb_release -a
Result (CLI output):
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04 LTS
Release: 22.04
Codename: jammy
Good evening, I was having the same problem which was basically the lack of libssl1.1
What I did to solve it was to add the repository that contains this lib to download, in this case I used the focal repository.
Use this command in your terminal to add it to your system:
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
Then do an update:
sudo apt-get update
And finally install the library:
sudo apt install libssl1.1
After installed try to install mongodb again, if it worked I'm glad to have helped you, if the problem persists I don't know how I can help you :(

Unable to locate package mongodb-org

I'm not able to install mongoDB on my ubuntu 22.04
~$ sudo apt-get update
~$ sudo apt-get install -y mongodb-org
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package mongodb-org
Then I tried this
~$ sudo apt-get install -y mongodb
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package mongodb is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'mongodb' has no installation candidate
You have maybe missed the point with the repo , check the exact steps here
For mongoDB 5.0 it is expected to create this apt list:
/etc/apt/sources.list.d/mongodb-org-5.0.list
as follow:
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/5.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-5.0.list
and then executing:
sudo apt update
So the new repo to be considered ...

Hi, I'm trying to install mongodb on linux but got an error

I'm installing mognodb following step by step of the documentation https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/ but getting an error at the step sudo apt-get install -y mongodb-org. Can't find any info to fix this problem.
The following packages have unmet dependencies:
mongodb-org : Depends: mongodb-org-shell but it is not going to be installed
Depends: mongodb-org-server but it is not going to be installed
Depends: mongodb-org-mongos but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Alos I've tried to install the dependencies one by one, but still getting the same error that points on other dependencies.
Import the public key used by the package management system
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5
Create a list file for MongoDB.
In Ubuntu 12.04 (deprecated):
echo "deb http://repo.mongodb.org/apt/ubuntu precise/mongodb-org/3.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.0.list
In Ubuntu 14.04:
echo "deb [ arch=amd64 ] https://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/3.6 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.6.list
In Ubuntu 16.04:
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.6 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.6.list
Reload local package database.
sudo apt-get update
It will throw a warning
W: http://repo.mongodb.org/apt/ubuntu/dists/trusty/mongodb-org/3.0/Release.gpg: Signature by key 492EAFE8CD016A07919F1D2B9ECBEC467F0CEB10 uses weak digest algorithm (SHA1)
Just Ignore It.
Install the MongoDB packages.
sudo apt-get install -y mongodb-org
After installation you can start MongoDB using
sudo service mongod start

postgresql-client-13 : Depends: libpq5 (>= 13~beta2) but 12.3-1.pgdg18.04+1 is to be installed

I want to try new PostgreSQL and follow this instruction. But installation fails:
$ sudo apt install postgresql-client-13
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
postgresql-client-13 : Depends: libpq5 (>= 13~beta2) but 12.3-1.pgdg18.04+1 is to be installed
E: Unable to correct problems, you have held broken packages.
I also tried this instruction to resolve unmet dependencies
What did I wrong and how to install psql 13?
UPD
Content of my sources.list.d:
kes#kes-X751SA /etc/apt/sources.list.d $ cat pgdg.list
deb http://apt.postgresql.org/pub/repos/apt/ bionic-pgdg main
kes#kes-X751SA /etc/apt/sources.list.d $ cat pgdg-testing.list
deb http://apt.postgresql.org/pub/repos/apt/ bionic-pgdg-testing main 13
Also:
$ sudo apt-cache policy postgresql-13
postgresql-13:
Installed: (none)
Candidate: 13~beta2-1.pgdg18.04+1
Version table:
13~beta2-1.pgdg18.04+1 100
100 http://apt.postgresql.org/pub/repos/apt bionic-pgdg-testing/13 amd64 Packages
Had the same problem.
in /etc/apt/sources.list.d/pgdg.list where you have
deb http://apt.postgresql.org/pub/repos/apt/ focal-pgdg main
change it to
deb http://apt.postgresql.org/pub/repos/apt/ focal-pgdg main 13
then run
sudo apt update
and then you can do
sudo apt install postgresql-13 postgresql-client-13
that worked on my machine.
Just FYI:
WARNING: The data format may change between beta releases. Be prepared
to pg_dump the database contents before you upgrade the package to a
newer beta or to a final release. Check the release notes before
upgrading.
try aptitude instead of apt-get
sudo apt-get install aptitude
sudo aptitude install <package-name>
https://askubuntu.com/a/1056378/1087086
Finally at my docker container I do next commands:
RUN yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
RUN yum -y install llvm5.0-devel
RUN yum -y install centos-release-scl-rh
RUN yum -y install llvm-toolset-7-clang
#RUN rpm -Uvh https://yum.postgresql.org/11/redhat/rhel-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm --replacepkgs
#RUN yum-config-manager --enable pgdg13-updates-testing
RUN yum -y install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
RUN yum -y install postgresql13 postgresql13-devel
Commented out lines were for case before 13.1 was released

Why I can't install a specific version of MongoDB?

I want install mongoDB 2.6.6, i follow this tutorial (http://docs.mongodb.org/manual/tutorial/install-mongodb-on-ubuntu/)
daniela.morais#tusk:/var/lib$ sudo apt-get install -y mongodb-org=2.6.6 mongodb-org-server=2.6.6 mongodb-org-shell=2.6.6 mongodb-org-mongos=2.6.6 mongodb-org-tools=2.6.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Version '2.6.6' for 'mongodb-org' was not found
E: Version '2.6.6' for 'mongodb-org-server' was not found
E: Version '2.6.6' for 'mongodb-org-shell' was not found
E: Version '2.6.6' for 'mongodb-org-mongos' was not found
E: Version '2.6.6' for 'mongodb-org-tools' was not found
To install mongodb 2.6 you'll need to follow this tutorial: http://docs.mongodb.org/v2.6/tutorial/install-mongodb-on-ubuntu
After adding the public key,
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10
the differentiating step is adding this source:
echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list
Then you can install 2.6 with
sudo apt-get update
sudo apt-get install -y mongodb-org
When I ran this installation on Ubuntu I get 2.6.8. You can check by using
mongod --version
If you enter apt-cache show <pkgname> it will give you a list of versions that are available form your package repository.
Try: apt-cache show mongodb-org.
If you enter apt-cache show mongodb-org | grep Version it will show you only the version numbers.
If you get "E: No packages found", you need to create the file /etc/apt/sources.list.d/mongodb-org-3.0.list as described on the page you linked first, then run sudo apt-get update.