I'm trying to update my mongodb version on my raspberry pi. I've runned following commands

$ sudo apt-get install mongodb

So far so good. I can access the mongo shell by typing mongo in the console. I can start the mongodb with the service:

$ sudo service mongodb start

The mongodb version is 2.4.14.

The mongodb works fine in projects. My problem is that in some of my mongo queries I use the $lookup stage. This service was released in version 3.2. Therefore my queries won't work with version 2.4.14.

I've tried to read the documentation (which there is not so much off??) to update my mongodb but I can't find a proper answer. So my question is: Is it possible to update my mongodb on my RaspberryPi, and if yes, how?

My OS informations on my raspberry pi:

Linux myRaspberryPi 4.9.41-v7+ #1023 SMP Tue Aug 8 16:00:15 BST 2017 armv7l GNU/Linux

PRETTY_NAME="Raspbian GNU/Linux 9 (stretch)"
NAME="Raspbian GNU/Linux"
VERSION="9 (stretch)"


  • Unfortunately Raspian is still 32-bit (as indicated by armv7l in your output). If you are open to changing Linux distros you could perhaps try Arch Linux ARM which does have a 64-bit kernel available for Pi3 (aarch64) and a community build of MongoDB 3.4: archlinuxarm.org/packages/aarch64/mongodb. I wouldn't have high performance expectations for running a full database server on a Pi; you will likely be better off using a more lightweight solution or pointing to a separately hosted database.
    – Stennie
    Commented Dec 12, 2017 at 1:14
  • @Stennie I found out that the solution would be to change my OS. And I will install Arch Linux ARM instead. Since the I my web application and my Database on the same server, so far the perfomance has been great. But perhaps it will worsens when the database grows. But thanks for a helpfull answer!
    – crellee
    Commented Dec 12, 2017 at 8:38

2 Answers 2


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.

  • Makes sense. But i'm still getting problems. On mongodb websites they guide you how to install mongodb on Debian. docs.mongodb.com/v3.4/tutorial/install-mongodb-on-debian I have Debian 9 on my raspberry pi and they only link to Debian 7 and 8. So I guess this is gonna be or less impossible for now?
    – crellee
    Commented Dec 9, 2017 at 9:03

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.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.