MongoDB is available in the Rasbian repo, at least for Jessie.
You can install with:
apt-get install mongodb
Unfortunately, it is only v2.4.10-5 whereas the current version is v3.2 or so I think.
It seems from the issues list that MongoDB has some coding issues that make it difficult to support non x86/amd64 platforms.
Update June 2017
The version on ...
Please note that this answer only applied to the 256 MB version of the Raspberry Pi. The 512 MB version should have sufficient free memory to compile MongoDB without additional adjustments
While reading about low-memory situation's in general, I found suggestions to simply increase the swap space to remedy the situation.
So, after reading bearbin's answer, ...
From the tutorial you linked to:
MongoDB only provides packages for 64-bit builds of Debian 7 and 8.
Although the Pi3 has a 64-bit processor, Raspbian is only a 32-bit OS.
Also, see this related question.
It shows an error, because the correct service name is mongodb and the tutorial contains a typo.
service mongodb start
and enjoy MongoDB:
MongoDB shell version: 2.4.10
connecting to: test
Server has startup warnings:
Fri Dec 30 19:04:35.967 [initandlisten]
Fri Dec 30 19:04:35.967 [initandlisten] ** NOTE: This is a 32 bit MongoDB binary.
You didn't specify OS requirement, though you hint at using Raspbian.
Another option is to use ArchLinux ARM. Arch always has the most up-to-date software available, great support for ARM and for things not available in the official repository, the Arch User Repository.
I see looking at the Arch ARM repository that MongoDB 2.6.8 is available. And if you ...
I made a shell script that will install the latest node, npm, and mongoDb. This process takes six hours to compile. The node, npm, and mongoDb shell script can be found here: https://github.com/audstanley/Node-MongoDb-Pi/blob/master/Install-Node-MongoDb-Pi.sh
But, if you just want to compile & install MongoDb:
You can copy past this block of code in, ...
The Raspberry PI 3 is a 64-bit ARM architecture, which is supported in MongoDB 3.4. The shell command you need to run to add the right repository for this architecture is:
echo "deb [arch=arm64] http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.4.list
Otherwise, I think instructions for ...
I would first try to remove the offending package with
sudo apt-get purge libboost-filesystem
or perhaps try to remove the damaged file with
sudo rm /var/lib/dpkg/info/libboost-filesystem1.58.0:armhf.triggers
then try to install mongodb again.
If that doesn't help, I'd simply reflash the OS and restart from scratch, unless I had a very good reason not ...
You are using Raspbian. This is only built with a 32 bit architecture armhf. I seems you have downloaded MongoDB with the 64 bit architecture arm64. You cannot run 64 bit programs on a 32 bit architecture. You either have to use a 32 bit MongoDB or use a 64 bit operating system. There is a 64 bit Raspberry Pi OS in beta test. You can try to use that.
Quote from bug report SERVER-1811
MongoDB is pleased to announce the 64-bit ARM development release for
both its Community and Enterprise offerings. This encompasses the core
server components including the shell, mongod and mongos processes,
and the server tools. ARM support will apply for Ubuntu 16.04 64-bit
on ARMv8 or newer. Please note that ...
NoSQL databases such as MongoDB were developed for solving different problems than SQL databases. MongoDB, for example, is a document-oriented database, which might be an unusual application for a Raspberry Pi given its relatively small store (e.g., 16GB SD card).
A more typical Raspberry Pi database application might, for example, involve sensor-based ...
MongoDB Is In The Repositories
You just need to install MongoDB, right?
It is already compiled and available in the Raspbian repositories:
pi@raspberrypi:~ $ apt-cache search mongodb
mongodb - object/document-oriented database (metapackage)
mongodb-clients - object/document-oriented database (client apps)
mongodb-dev - object/document-oriented database ...
You can directly install mongodb_3.4.18-2+b1 (ARM64) on Raspbian over debian.org, so, follow the procedure:
1. Download the package:
2. Install the package:
sudo dpkg -i mongodb_3.4.18-2+b1_arm64.deb
In addition, you may face a problem because of ...
I'm confirming Steve's short-term answer, here. The committee thought opening a mongo to external clients might be ... hard. Instead, you simply get on a non-Pi console and cast this magical spell:
sudo nano +11 /etc/mongodb.conf
make the bind_ip lines look like this:
# bind_ip = 127.0.0.1 # oh aren't WE the prude?
bind_ip = 0.0.0.0 # hello, cloud
Unusually, the Raspbian repositories are out of sync with the official Debian repositories which host version 3.2.11 for Stretch. I checked the Raspbian repos and Raspbian Stretch only has 2.4.14 available.
There are unofficial builds for Stretch, mind you, such as one from Andy Felong which provides 3.0.14.
If you're desperate you could also try building ...
The problem was with php.ini file, on 1st try, adding extension=mongodb.so and saving setting didn't save despite showing the change in the file on opening.
After a reboot of the system, I edited the file again and this time, it worked. I don't know why such thing happened and didn't save but it works fine now.
MongoDB 3.2 requires a 64-bit OS. Current Raspberry Pi official OSs are still 32-bit, even for the R-Pi 3. You can "experiment" with MongoDB 3.2 on an R-Pi 3 using Debian buster. See blog post at andyfelong.com
You can also find 32-bit MongoDB 3.0.x binaries for Raspbian Stretch, there.
Once you depart from stable software releases all bets are off. It may require newer version of libraries which are incompatible with the rest of the installed packages. In other words you could break your system.
If you are determined to carry on then download the required sources and build on the Pi.
I disagree with the comments that MongoDB has issues with ARM processors. According to this post here, MongoDB v3.3 has been supported on the 64-bit ARM version of Ubuntu 16.04 since August, and full support was announced for v3.4.
You can read instructions on installing Ubuntu Mate for the Raspberry Pi from here, and download it from here. Only version 16....
You are following a guide for the desktop version of Ubuntu, therefore the repository you added is for a desktop CPU architecture, not the armhf architecture the Raspberry Pi needs. Try this guide for Raspbian.
The official repositories will be Raspbian if you are using Raspbian.
It's in the latest Raspbian, but not in the stable Raspbian. So you could consider upgrading to jessie.
Note, the -s option is used to show what would be done.
harry ~ $ sudo apt-get -s install mongodb
Reading package lists... Done
Building dependency tree
Reading state ...
I have an option that might work. However, it will probably dramatically slow down your compilation process.
You need to set up ZRAM on your Pi. Basically it compresses the used RAM to allow you to use more, but at the cost of more CPU usage.
We will follow the instructions here but I will put them in the post for easy viewing.
So first, you need to be ...
There seems to be some breaking changes in the versions 3.x and 4.x of express.
3.x used the
4.x now uses
A number of user have been hit by the same error message
Arch Linux for Pi has MongoDB v3+ in its repos I believe.
If you are staying with Rasbian, at least Jessie (not sure about Wheezy) has a version too but it is only v2.4
All you need to do is:
sudo apt-get update && sudo apt-get install mongodb
Then edit the config:
sudo nano /etc/mongodb.conf
Make sure you add the external IP address to the ...